Go Back   CodingForums.com > :: Server side development > Apache configuration

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 01-29-2009, 03:21 AM   PM User | #1
kcfried
New to the CF scene

 
Join Date: Jan 2009
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
kcfried is an unknown quantity at this point
Question Yet more .htaccess help requested...

Hi all. I'm very new to the non-windows side of the web development, and even newer to regex and .htaccess rewrites. I've dug through the forums, and while there's a ton of info, I'm still a little lost.

What I'm trying to do is set upa site that will route like this:

www.mysite.com/SomeName/ -rewrites to: index.php?id=abc123
www.mysite.com/anothername/ - rewrites to: index.php?id=def456

and so on - to the tun of about 60-70 unique IDs. I also have to make sure that the faux directory name is case insensitive.

Any help is appreciated. thanks in advance!
kcfried is offline   Reply With Quote
Old 02-04-2009, 12:40 AM   PM User | #2
CyberPirate
Regular Coder

 
Join Date: Jan 2009
Location: Norway
Posts: 118
Thanks: 8
Thanked 2 Times in 2 Posts
CyberPirate is an unknown quantity at this point
Try this one

Code:
RewriteRule ^([^/]*).*$ index.php?id=$1
It should make www.mysite.com/index.php?id=abc123 into www.mysite.com/abc123
CyberPirate is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 10:25 PM.


Advertisement
Log in to turn off these ads.