Hi Guys,
I’m running into a problem when I try to serve my ember app through Apache. Because the location is set to “history” and not “hash”, Apache is trying to load the magic ember routes which don’t exist as files. 腾讯应用宝官网-全网最新最热应用及游戏下载 throws a 404 because there is no login.html.
I’ve done a bit of scouring and its surprising that there isn’t much on this which leads me to believe that not many people deploy ember apps on apache.
So it’s suggested I write Apache URL Rewrite rules, but the one’s I have tried don’t seem to be working.
Options +FollowSymLinks
RewriteEngine On
RewriteBase /
RewriteRule ^(.*)$ index.html [L]
and
Options FollowSymLinks
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.html$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.html [L]
</IfModule>
Don’t work.
Does anyone have any idea of what to do other than go back to “hash”?
Regards, Clueless person.