Jump to content

Recommended Posts

HI all

 

Probable a very simple answer but I am struggling, I have a .htaccess file with specific rules, but I also want a line on there for any pages that aren't captuured by the previous rules.

 

I currently have the following .htaccess

 

 

RewriteRule ^news$ news.php [L]
RewriteRule ^gallery$ gallery.php[L]
RewriteRule ^fixtures$ fixtures.php [L]
RewriteRule ^about-us$ profile.php [L]
RewriteRule ^sponsors$ sponsors.php [L]
RewriteRule ^contact$ contact-us.php [L]
RewriteRule ^gallery/([^/\.]+)/([^/\.]+)?$ gallery.php?id=$1&identifier=$2 [L]
RewriteRule ^news/([^/\.]+)/([^/\.]+)?$ news.php?id=$1&identifier=$2 [L]
RewriteRule ^feed$ rss.php?lang=en [L]
RewriteRule ^kids-club$ kids-club.php [L]
RewriteRule ^business-club$ business-club.php [L]
RewriteRule ^merchandise$ shop.php [L]
RewriteRule ^ticket-office$ tickets.php [L]
RewriteRule ^my-first-skid$ my-first-skid.php [L]
RewriteRule ^riders$ riders.php [L]
RewriteRule ^riders/([^/\.]+)/([^/\.]+)?$ riders.php?id=$1&identifier=$2 [L]
RewriteRule ^wall-of-honour$ wall-of-honour.php [L]
RewriteRule ^commercial$ commercial.php [L]
RewriteRule ^travel$ travel.php [L]
RewriteRule ^supporters-club$ supporters-club.php [L]
RewriteRule ^live$ live.php [L]
Rewrit­eRule ^([A-Z­a-z­0-9­-]+)$ page.p­hp?­page=$1 [L]

 

All of them work except the bottom one, so if I was to type in the url of domain.com/season-tickets, I would want that rewritten to domain.com/page.php?page=season-tickets

 

Any help would be great

 

Thanks

Link to comment
https://forums.phpfreaks.com/topic/302736-rewrite-rule-not-rewriting/
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.