Status
Not open for further replies.

Ccucu

Active Member
101
2008
0
30
Hey guys.
I need a little help, I'm a noob at url rewriting and I need to do it fast for a site.

I have redesigned a site using custom code.

Old site was based on wordpress.

I have all the content from old site in the new database and pages are set up.
Wordpress had friendly urls, new site doesn't and I need to keep urls because they are indexed well in Google.

So I need to turn:

www.site.com/gallery.php?id=102

into:

www.site.com/gallery/gallery-name/

Please help me out :)

Thanks
 
2 comments
Oh walla, I wondered why no one replied to this one :P Simple one, I actually struggled with something similar on my site too.

Here is the following code to do it


Code:
RewriteEngine On
RewriteRule ^gallery/([^/]*)$ /gallery.php?id=$1 [L]
 
Status
Not open for further replies.
Back
Top