-
-
Save jbutko/6b500210b4c6811bca54 to your computer and use it in GitHub Desktop.
# this ensures support for pretty links even after page refresh (F5) | |
<IfModule mod_rewrite.c> | |
Options +FollowSymlinks | |
RewriteEngine On | |
# Don't rewrite files or directories | |
RewriteCond %{REQUEST_FILENAME} -f [OR] | |
RewriteCond %{REQUEST_FILENAME} -d | |
RewriteRule ^ - [L] | |
# Rewrite everything else to index.html to allow html5 state links | |
RewriteRule ^ index.html [L] | |
</IfModule> | |
# via https://github.com/angular-ui/ui-router/wiki/Frequently-Asked-Questions#how-to-configure-your-server-to-work-with-html5mode |
Hello,
I am also getting the same problem. If I refresh http://anaoh.com/home, It shows the directory index.
Please let me know if you have any suggestion.
Raja K
Need Help!!
On refreshing pages " localhost/blog/list " or opening pages "localhost/blog/" does not work while links like "localhost/blog" open even on refreshing.
To those still facing this problem, it's more common now to use the FallbackResource
directive instead of adding a mod_rewrite block. Read more here.
This works perfectly, but in child routing, it throughs errors,
"Uncaught SyntaxError: Unexpected token"
and page doesn't get loaded.
Need help on this
I am also having the same problem.
Ever since I turned on the html5 mode, all emails links and forced browser reloads are breaking.
Any help how to overcome this scenario?
@yves-s: Did you solve this? I'm getting the same problem