Forum

Thread tagged as: Question

Clean URLs with content custom

How do I use the clean url with content custom and list detail?

Erick Green

Erick Green 0 points

  • 6 years ago

Create a .htaccess file with...

RewriteRule ^([a-zA-Z0-9-/]+)$ /mypage.php?s=$1 [L]

Make sure you remove mypage.php?s= from your template links

Cant get it to work right. Want to remove the "p-productions.php?s=" in the picture below. Is this possible? https://bildr.no/image/c1grRlgy.jpeg

Rachel Andrew

Rachel Andrew 394 points
Perch Support

Yes that is possible but you are going to need to give us more to go on than it isn't working right. What have you tried? What is happening?

Ive created htaccess with:

<IfModule mod_rewrite.c>  
    RewriteEngine on  
    RewriteRule ^([a-zA-Z0-9-/]+)$ /mypage.php?s=$1 [L]
</IfModule>

Get an 404 on "my-domain.com/projects/" page and no changes on "my-domain.com/projects/project.php?s=".

Drew McLellan

Drew McLellan 2638 points
Perch Support

Do you have any rewrite rules working? Have you established that your server has support?

This is my only rewrite rule and i have not checked my server for support. What kind of support do my server need?

Drew McLellan

Drew McLellan 2638 points
Perch Support

Does you server have mod_rewrite enabled?

Yes it does.

Drew McLellan

Drew McLellan 2638 points
Perch Support

Ok, great. So can you get any rewrite rules to work? i.e. is your configuration being read?