AngularJS routing 404 error with HTML5 mode

HTML5 mode requires URL rewriting. From the Docs: HTML5 Mode Server side Using this mode requires URL rewriting on server side, basically you have to rewrite all your links to entry point of your application (e.g. index.html). Requiring a <base> tag is also important for this case, as it allows AngularJS to differentiate between the … Read more

Tomcat 404 error: The origin server did not find a current representation for the target resource or is not willing to disclose that one exists [duplicate]

Problem solved, I’ve not added the index.html. Which is point out in the web.xml Note: a project may have more than one web.xml file. if there are another web.xml in src/main/webapp/WEB-INF Then you might need to add another index (this time index.jsp) to src/main/webapp/WEB-INF/pages/

Routing for custom ASP.NET MVC 404 Error page

I’ve tried to enable custom errors on production server for 3 hours, seems I found final solution how to do this in ASP.NET MVC without any routes. To enable custom errors in ASP.NET MVC application we need (IIS 7+): Configure custom pages in web config under system.web section: <customErrors mode=”RemoteOnly” defaultRedirect=”~/error”> <error statusCode=”404″ redirect=”~/error/Error404″ /> … Read more

urlencoded Forward slash is breaking URL

Apache denies all URLs with %2F in the path part, for security reasons: scripts can’t normally (ie. without rewriting) tell the difference between %2F and / due to the PATH_INFO environment variable being automatically URL-decoded (which is stupid, but a long-standing part of the CGI specification so there’s nothing can be done about it). You … Read more

Django, creating a custom 500/404 error page

Under your main views.py add your own custom implementation of the following two views, and just set up the templates 404.html and 500.html with what you want to display. With this solution, no custom code needs to be added to urls.py Here’s the code: from django.shortcuts import render_to_response from django.template import RequestContext def handler404(request, *args, … Read more