FreePgs.com Forum
June 27, 2022, 10:26:59 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
News: The "Support Requests" forum is now viewable by guests.
 
   Home   Help Search Login Register  
Pages: [1]   Go Down
  Print  
Author Topic: Mod_Rewrite  (Read 2645 times)
Osprey
Verified Account
Full Member
*

Karma: +0/-0
Offline Offline

Posts: 226

Blog entries (0)

View Profile WWW
« on: July 14, 2006, 05:57:58 PM »

Hey Guys, I'm having a little trouble with Mod_Rewrite.. hoping someone can help.

The current code in my .htaccess file:
Quote
RewriteEngine On
RewriteBase /
RewriteRule ^secret/(.*) secret.php?id=$1

Basically, i want domain.com/secret/$number to act as domain/secret.php?id=$number -- I can't see what i've done wrong, i've used similar code elsewhere and it worked fine? Any help much appreciated.

I even stuck a [R] on the end of the rule to try and get it to redirect but that didn't work either.

Osprey
Logged

Osprey
Verified Account
Full Member
*

Karma: +0/-0
Offline Offline

Posts: 226

Blog entries (0)

View Profile WWW
« Reply #1 on: July 15, 2006, 06:10:49 AM »

I think i've come accross the problem.. i think it's because the page i was using (secrets.php) had the same name as the folder. Is there some kind of overriding HTACCESS preventing it from working? In any case it's okay now i just renamed the secrets.php page.

Osprey

Edit:

Hmm, odd. It wasn't that after all. I'm not sure whats going on but it doesn't like using "secret" as a "false directory" (If that makes sense) but "secrets" is fine. It's annoying because i really wanted secret... i guess i'll keep playing.

Edit2:

Oh yes it was - Wahey! Fixed it.
« Last Edit: July 15, 2006, 06:16:06 AM by Osprey » Logged

FreePgs.com Forum
« Reply #1 on: July 15, 2006, 06:10:49 AM »

 Logged
Pages: [1]   Go Up
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!