apache - Rewriting URL's with and without trailing slash -
i'm @ wits end on , don't understand apache (like, @ all) or care to.
i'm attempting able visit site going url in 2 ways:
example.com/page
example.com/page/
both using page.html data source. i've been told use multiviews (which enabling did nothing). i've seen done mod_rewrite.
current .htaccess not work.
options +followsymlinks -multiviews # turn mod_rewrite on rewriteengine on rewritebase / ## hide .php extension external redirection: rewritecond %{the_request} ^[a-z]{3,}\s/+([^.]+)\.html [nc] rewriterule ^ /%1/ [r,nc,l] ## internally redirect .php extension: rewritecond %{document_root}/$1.html -f rewriterule ^(.+?)/?$ /$1.html [l]
Comments
Post a Comment