Forum

Thread tagged as: Question

Trailing / on perch blog

Hi,

Is there any way to do this?

Thanks

Garth Holmes

Garth Holmes 1 points

  • 6 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

Can you elaborate?

Hi Drew,

Instead of having:

/blog/2015-05-26-kjh

have

/blog/2015-05-26-kjh/

I did it:

<IfModule mod_rewrite.c>  
    RewriteEngine on  
    RewriteBase /
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_URI} !(.*)/$
    RewriteRule ^(.*)$ https://domain.com/$1/ [L,R=301] 
    RewriteRule ^blog/([a-zA-Z0-9-/]+)$ /blog/post.php?s=$1 [L]
</IfModule>

Thanks