but when uploaded to my live server, those links with .html will display error msg
(HTTP Error 404.0 - Not Found)
This problem occurs for one or more of the following reasons:
The specified directory or file does not exist on the Web server.
The URL contains a typographical error.
A custom filter or a custom module restricts access to the file. The filter or the module sends the "HTTP Error 404.0" error message back to the client as a response.
To resolve this problem, use one of the following methods:
Make sure that the requested resource is at the location that the URL points to.
Review the URL that you open in the Web browser.
Make sure that no custom filters or modules restrict access to the file that you want to browse.
hope it can give some tips to troubleshoot, moreover, it's also recommended to post this issue to IIS forum(http://forums.iis.net/), more IIS professionals will help you there.
Regards
MSDN Community Support
Please remember to click "Mark as Answer" the responses that resolved your issue.
If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.
Member
103 Points
790 Posts
URL Rewrite with extension not working in live server (localhost is pretty good)
Nov 09, 2013 08:39 PM|kengkit|LINK
hi guys, i using URL rewriter in my web.config and it's working pretty good for me when testing in localhost.
for an instance,
1) http://localhost/mywebsite/electronics/smartphone/samsung/
2) http://localhost/mywebsite/electronics/smartphone/samsung/galaxy+core.html
but when uploaded to my live server, those links with .html will display error msg (HTTP Error 404.0 - Not Found)
1) http://www.demo.com/mywebsite/electronics/smartphone/samsung/ (working)
2) http://www.demo.com/mywebsite/electronics/smartphone/samsung/galaxy+core.html (not working)
web.config
Contributor
3390 Points
1079 Posts
Re: URL Rewrite with extension not working in live server (localhost is pretty good)
Nov 10, 2013 11:21 PM|kctt|LINK
Are you sure you configure correct Asp.net version and mode for application pool?
Member
103 Points
790 Posts
Re: URL Rewrite with extension not working in live server (localhost is pretty good)
Nov 11, 2013 12:49 AM|kengkit|LINK
Hi kctt,
I have checked my live server is using framework 4.0 and Classic Mode for application pool. (my website not able to run if using integrated mode)
And my localhost is using framework 4.0 * but not sure how to check mode for application pool (as i using vs2010 to start debug) please advise. tq
* <compilation debug="true" strict="false" explicit="true" targetFramework="4.0" />
Member
103 Points
790 Posts
Re: URL Rewrite with extension not working in live server (localhost is pretty good)
Nov 11, 2013 07:40 PM|kengkit|LINK
hi sir, any advise on my problem? and may i know how can i make my website run under integrated mode (application pool) during deployment?
All-Star
32817 Points
3815 Posts
Re: URL Rewrite with extension not working in live server (localhost is pretty good)
Nov 18, 2013 03:10 AM|Angie xu - MSFT|LINK
Hi kengkit
This problem occurs for one or more of the following reasons:
To resolve this problem, use one of the following methods:
hope it can give some tips to troubleshoot, moreover, it's also recommended to post this issue to IIS forum(http://forums.iis.net/), more IIS professionals will help you there.
Regards
Please remember to click "Mark as Answer" the responses that resolved your issue.
If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.
All-Star
25749 Points
10436 Posts
Re: URL Rewrite with extension not working in live server (localhost is pretty good)
Nov 19, 2013 02:11 PM|jeff@zina.com|LINK
Simple Possibility:
Is the live server set to serve static files (such as HTML)?
Jeff
Member
103 Points
790 Posts
Re: URL Rewrite with extension not working in live server (localhost is pretty good)
Nov 19, 2013 07:14 PM|kengkit|LINK
Hi jeff,
May i find out with you how can i confirm my live server set to serve static file?
* my live server can open .html with no problem ^^
TQ