When running a polymer-shop-app on localhost I can go to localhost:8080/page and it loads, as well as on a page refresh.
However, once deployed in IIS, I can navigate to localhost:8080/page through the app, but one a page refresh I get a 404 - File or directory not found error.
Is there something that can be set within IIS to change this behavior and properly load the route and route data on a page refresh.
Related
I was getting "HTTP 403 error Microsoft Edge can’t get to this page", while launching an application from IIS in Windows 10. Please suggest a solution for this.
thanks
If all permissions are set and even though your website shows 403 forbidden, most likely the default page is not set for your website. With IIS, you can configure the default document as follows.
Connect to IIS.
Expand the sites and select the desired website.
From right hand side feature view, click on Default Document.
Set your desire default page and save the settings.
While you browse any website, IIS searches for the default page to be displayed. If the first default document is not available, IIS will look for the next default page from the list. When IIS is unable to find any match and directory listing is enabled for that particular website, IIS will show you the list of folders. If directory listing is disabled, IIS will return an HTTP Error 403 - Forbidden message to the browser.
If an empty application gives you a 403 I can think of two immediate reasons.
The permissions are wrong. You might need to give the application pool user (IIS AppPool\NAMEOFAPPPOOL with recommended configuration) read permission to the directory.
You don't have any content. If you try to access a directory in IIS you will get a 403. Add a file and try to access that directly, or a Default.aspx or index.html file to the directory you're trying to access.
I'm hosting a simple html file in IIS 7.5 on Windows Server 2008R2. I've assigned the site a default application pool with No Managed Code. There is nothing more in the folder other than the index.html file and a css file and I haven't changed any other setting within IIS.
On the first request and after every site restart of the site a 500 Internal Error is returned. The following error in the HTTPERR log seems to be the cause:
2014-07-04 etc .......- - - - - Timer_ConnectionIdle -
On subsequent requests the page loads fine, no problems. Why is this error being thrown on first request and how can I fix this? It doesn't seem to be related to the application pool as it doesn't happen when I recycle it, only when I stop and restart the site.
I am having a torrid time trying to figure out why I cannot display http://localhost in the web browser.
I keep getting the 404 not found error. I tried looking in the wwwroot folder and added the http://localhost/iisstart.html still nothing happened.
There is a web service and a web application added to the default web site and I am not sure if this has something to do with this but all this worked fine previously.
I'm trying to return a custom 404 page using IIS6. (I have a site that is mostly .shtml pages built using movable type). I have tried it 2 ways:
1) set the 404 error handler in IIS to be type "file" with the path \404.html. This works, but it also means that I can't import the header and footer of my site (hence the .shtml) Trying to point the 404 error handler to 404.shtml results in the default 404 page...i guess IIS can't process shtml files in the 404.
2) set the type to "URL". This works great, except that the response code is no longer 404! Its a 200.
How can I get IIS to respond with a 404 response code with the content of my 404.shtml file?
Given that it's IIS, adding
<% Response.Status = "404 Not Found" %>
to the top of 404.shtml should change the response code to 404.
I am not on a windows machine so I am unable to test it at the moment to verify.
Update:
I was finally able to run a few tests on a IIS 6. As you mentioned in a comment to my post, an .shtml file does not allow script commands to run. So there are at least two ways to work around this:
Instead of naming your custom 404 handling page 404.shtml, name it 404.asp. The user should never see the actual name of the page so it shouldn't cause any issues. Note that "Active Server Pages" must be set to 'Allowed' in the Web Service Extensions folder of IIS.
Modify the page extension mapping for .shtml to use asp.dll instead of ssinc.dll. You can do this from IIS by selecting the website and viewing Properties -> Home Directory tab -> Configuration -> Mappings tab. Note that this is far from an ideal solution because now all your .shtml files will be processed by asp.dll. This could cause your pages to render more slowly (assuming asp.dll processes files more slowly than ssinc.dll due to greater complexity) and violates the principle of least privilege.
If neither of the options fit your situation, then it may still be possible but the solution isn't immediately obvious to me.
In IIS Manager, open the Properties of your Web site (or virtual dir) and go to the Custom Errors tab. There you can set which file is sent in case of each error code, including 404.
I have a web site with a child directory set up as an application. I set up the application to use a custom 404 page. When I navigate to the url and put in a non existent page I get the following error message. Any other asp page in the application works fine. There isn't even any script in the 404 page... just plain html so I'm not sure what is causing this. I've tried creating an application pool specifically for this application but that didn't help. Thanks.
Error message: The specified request cannot be executed from current Application Pool
Try to create a registry key with the name IgnoreAppPoolForCustomErrors (type DWORD, value 1) in HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\W3SVC\Parameters\
See http://blogs.msdn.com/rakkimk/archive/2006/09/01/735684.aspx or http://www.yanghengfei.com/show-131-1.html for more information - seems to be a not so uncommon problem.