I have a c# asp.net application with the framework v4.0 . In my application, I am using some resx file. When I locally run my application, all is normal (the localization work pretty well). Now I am trying to setup my application on iis 8 (The server with iis is a 2012 r2). The problem is all the control that are using the resx file to get the text property are empty.
So, given that all is working good locally and not on iis, is that iis need some special configuration to use the resx file properly ?
When you say you run it locally, are you running it through visual studio or are you running it off a local version of IIS? There are differences between configuration of IIS in visual studio and the "real" IIS, so you might want to start there. Also, are there any errors or warning being generated in the event viewer?
Related
I'm really new at this, never hosted an app before, everything I've done so far has been locally.
I have a windows server 2008 sp1 running at work, with IIS installed. I access to it via remote desktop, and I need to be able to deploy my app, first locally on the server, so computers that can access it (through LAN) are able to use it.
Right now, if I create a folder and put some data in it, with an html file, and go to "localhost" in a browser, I can see the rendered html file.
The version installed is IIS 7.0, and my app is uses the MVC pattern, and .net framework 4.6.
If on my windows 10 PC I start my app (vs 2017) I can see it on my browser.
I want to be able to do what I do in my PC but on the server. How can I do this?
Update:
I tried Publishing the app through vs but that is on my windows pc and getting a lot of errors. What I know so far is that a guy from Networks gets the app by the developers and they publish it, but I don't know what kind of files does he need.
I followed tutorials but I just can't apply them.
As I said earlier, I have visual studio installed on my w10 PC, and tried publishing through that app to the ip where the server is, getting a lot of errors.
I don't know what to do, I'm really trying a lot of different things, but I don't even know how the app is supposed to look to be run in any way that is not how I run it in visual studio.
UPDATE:
I'm getting this error when I try to publish locally
Here is the Outline of what we need as per OPs requirement
In VS publish the App to a folder
Sort out the server prerequisites:
Turning Windows Feature On or Off for ASP.NET, ISAPI filters, ISAPI extensions, NET extensibility
Server should have .NetFramework installed
Copy the published folder to the Server
Configure IIS manager to add a new site and set physical path to published folder
I have created an MVC 5 website using Visual Studio 2015 on a Windows Server 2016 Machine.
I build and run the application from VS and it works great.
I published it locally, pointed IIS to the root folder.
The Application Pool is set to .Net CLR Version v4.0.30319.
When I try to access the page on the web, I get a generic error
500 - Internal server error.
There is a problem with the resource you are looking for, and it cannot be displayed.
There is nothing in the IIS logs.
Not sure how to get this error so I can see it...or if it is a more basic issue. Any ideas on the best way to proceed?
To configure within Microsoft Server 2016, do the following:
Make sure you've installed the feature set for Web Server & Hosting are installed.
If those are installed, create a directory such as: "C:\Program Files\Sample"
Publish your application to the directory
Open Internet Information System
Disable Default Site
Create a New Site
Create a Site Name "Sample" (Take note of the Application Pool Name)
Now link "C:\Program Files\Sample" in Physical Path
For now leave the binding defaulted, this will trigger wildcard
Uncheck Start Website Immediately
Navigate back to "C:\Program Files\Sample" (Accessible through IIS also)
Right-Click and go to Permissions
Choose add new user
Type in "IIS AppPool\Sample"
Choose access your application will require.
Apply those changes, then navigate and start your web-site.
If that doesn't work, you can check the following:
Application Pool:
Sample should of defaulted to integrated and 4.0, if not change it. If your utilizing .Net Core application, you want it to be Unmanaged Code
Programs and Features:
Make sure that you have .Net 3.5, 3.0, 2.0 enabled.
Hostable Web Core & Internet Information System (Under Web Server) for you.
World Wide Web Services Enabled, with the proper Application Development Features.
Dependencies:
You may have to install https://www.microsoft.com/download/details.aspx?id=53840
If you have Core, you'll need: https://aka.ms/dotnetcore-2-windowshosting
I'm writing an ASP.NET Web Forms project in Visual Studio 2013, but am having trouble moving it to my computer's IIS 7. Although the project launches successfully from Visual Studio and works properly, launching the version I put on IIS gives an HTTP 500 error: "localhost is currently unable to handle this request."
Here is my process:
Use the File System method of Visual Studio's Publish tool to publish the project to a folder on my computer.
Access IIS' Default Web Site, and set the Physical Path to the folder I published the application to.
If the project works from Visual Studio, why wouldn't it work in IIS?
I had a double entry for in my web.config, and it was causing the same issue: 500 error with no other clue.
The problem was I was submitting a Web Form Application instead of a regular Web Site. The former has additional files in it that makes it not work properly in IIS (at least, I've never been able to make it work).
Thankfully, making a blank Web Site in Visual Studio and copying the web pages over from the Web Forms application was a simple matter, and I got it working easily.
I had an entry made in the web.config
which caused this error...remove the line fixed this issue. so probably any error in web.config makes the browser to not load the server and hence the issue
I am trying to set up a .NET application locally to run with a different alias to 'localhost'. The application has a successful connection to the database and runs correctly when running as localhost.
In some of my projects, I am able to access the application on the browser by writing '.local' after the application name. For example, a project called toysandstuff can be accessed in the web browser with 'toysandstuff.local. instead of having to run it through Visual Studio and localhost.
I have this set up for some of my applications at work but i'm not sure how to configure IIS and Visual Studio to run the project as '.local' instead of using localhost.
Thanks in advance!
I have a MVC 5 web application that is working fine. But due to internal security reasons and restrictions of my organization, I cannot host it as a website. My current requirement is to make this app run on a particular computer that has IIS installed on it but no Visual Studio.
My application makes use of MS-SQL database, Entity Framework, C# razors and all other .NET dependencies that are usual in a MVC app, and my target framework is 4.5.1 .
What I Found : I googled a lot, what I got is to create a Virtual Directory using the inetmgr and create the application under that directory. But since already the application is created I cannot go for this fix.
Please help me out by providing some links to refer to or steps to solve this.
Thanks in advance for any help.
What you will need to do is to either:
Use Visual Studio to publish the website directly onto the machine which is hosting the IIS application, as shown here.
Use Visual Studio an publish the application to a folder location on your machine and then use remote desktop or some other method to move the published DLL's to the virtual directory of the application.
Essentially both of them do the same thing, but sometimes due to security reasons, option 2 is easier to accomplish.