Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>For those that thought the above answer was insufficient: What you want to do is enable your server to reroute all urls to your index.html page where Backbone.js will take care of the routing for you. The following steps will let you do this while still keeping the URL the same inside the address bar.</p> <p>If you're using Apache as your container, you need to enable a mod_rewrite module inside your application's .htaccess file.</p> <p>Inside your httpd file:</p> <p>1) Make sure that your "Override" command for your document root is enabled to "Override All" instead of "Override None"</p> <p>2) Enable the mod_rewrite.so module by uncommenting this line: </p> <blockquote> <p>LoadModule rewrite_module modules/mod_rewrite.so</p> </blockquote> <p>Inside your application's .htaccess file (if you don't have one, create one):</p> <p>1) If you have a <strong>IfModule mod_rewrite.c</strong> module already written, then copy these lines into one of the modules: </p> <blockquote> <blockquote> <p>RewriteEngine On <br/> RewriteRule ^/[a-zA-Z0-9]+[/]?$ /index.html [QSA,L]</p> </blockquote> </blockquote> <p>You should have something that looks like this:</p> <pre>&lt;IfModule mod_rewrite.c> RewriteEngine On RewriteRule ^/[a-zA-Z0-9]+[/]?$ /index.html [QSA,L] &lt;/IfModule></pre> <p><strong>Edit</strong></p> <p>Note: In Apache 2.2+, you can now use <a href="http://httpd.apache.org/docs/current/mod/mod_dir.html#fallbackresource" rel="noreferrer">FallbackResource</a> instead of mod_rewrite, it requires fewer lines and accomplishes the same thing.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload