Jump to content

Rewrite issues... almost there, but not quite?


torb

Recommended Posts

A wee bit confused here. OK, _very_ confused! This is the first time I work with mod_rewrite. I've been at it for a couple of hours now with no luck. :(

 

In essence, i want to shorten the URL's to the member profiles of my forum - but I want the relative links in these profiles to link to the correct places within the board.

 

This is my .htaccess as I've got it so far:

RewriteEngine On
RewriteRule ^([^/]*)/([^/]*)\.html$ /testboard/member.php?action=$1&member=$2 [L]

 

That supposedly turns the long url

http://www.mydomain.com/testboard/member.php?action=viewpro&member=torb

into the friendlier

http://www.mydomain.com/viewpro/torb.html

 

When browsing my forum, the link to my profile is still http://www.mydomain.com/testboard/member.php?action=viewpro&member=torb when I was hoping it would be http://www.mydomain.com/viewpro/torb.html. When I go to http://www.kult-rpg.com/viewpro/torb.html it displays my profile, only now all the relative links OUT of that page point to the wrong place, as do the relative images.

 

Can anybody please give me a hand here? Point out the obvious bit for me, please :)

 

Thanks,

-torb

Link to comment
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.