Hi,
Just starting using Couch and loving it so far.
I have one question though - how do I ensure that URLs are always displayed without the trailing slash?
For example, I currently get:
www.mywebsite.com/about/
www.mywebsite.com/contact/
But I would like:
www.mywebsite.com/about
www.mywebsite.com/contact
This is my about page htaccess code:
#about.php
RewriteRule ^about$ "$0/" [R=301,L,QSA]
RewriteRule ^about/$ about.php [L,QSA]
RewriteRule ^about/.*?([^\.\/]*)\.html$ about.php?pname=$1 [L,QSA]
RewriteRule ^about/([1-2]\d{3})/(?:(0[1-9]|1[0-2])/(?:(0[1-9]|1[0-9]|2[0-9]|3[0-1])/)?)?$ about.php?d=$1$2$3 [L,QSA]
RewriteRule ^about/[^\.]*?([^/\.]*)/$ about.php?fname=$1 [L,QSA]
RewriteRule ^about/[^\.]*?([^/\.]*)$ "$0/" [R=301,L,QSA]
Thanks in advance,
Chris
Just starting using Couch and loving it so far.
I have one question though - how do I ensure that URLs are always displayed without the trailing slash?
For example, I currently get:
www.mywebsite.com/about/
www.mywebsite.com/contact/
But I would like:
www.mywebsite.com/about
www.mywebsite.com/contact
This is my about page htaccess code:
#about.php
RewriteRule ^about$ "$0/" [R=301,L,QSA]
RewriteRule ^about/$ about.php [L,QSA]
RewriteRule ^about/.*?([^\.\/]*)\.html$ about.php?pname=$1 [L,QSA]
RewriteRule ^about/([1-2]\d{3})/(?:(0[1-9]|1[0-2])/(?:(0[1-9]|1[0-9]|2[0-9]|3[0-1])/)?)?$ about.php?d=$1$2$3 [L,QSA]
RewriteRule ^about/[^\.]*?([^/\.]*)/$ about.php?fname=$1 [L,QSA]
RewriteRule ^about/[^\.]*?([^/\.]*)$ "$0/" [R=301,L,QSA]
Thanks in advance,
Chris