Jump to content

What do I need? URL redirect query


richrock

Recommended Posts

Been mucking in with .htaccess, had some success in the past, but always find it a mare  :(

 

I need to redirect a shortened URL to a full original url - I don't need to show the shortened URL in the address bar, what's important for the client is that the URL works.

 

eg :

www.mydomain.com/willmotspage would redirect to index.php?option=com_content&view=article&id=130:paul-a-vanessa-willmott&catid=36:full-time-evangelists&Itemid=56&authid=91

 

a horrendous url, but the built-in SEO will take care of most of that - I guess I'm looking for a config that's similar to these tinyurls I keep seeing.  I have tried this :

 

Redirect /willmott http://mydomain.co.uk/index.php?option=com_content&view=article&id=130:paul-a-vanessa-willmott&catid=36:full-time-evangelists&Itemid=56&authid=91 [L]

 

but it's not redirecting properly, as some info on the page is quite dependent on the GET information sent....  Not sure what's going on there....  I tried it without the [L], also using R=301, and doing Redirect ^willmott...

 

:'(

Link to comment
Share on other sites

RewriteRule ^ willmott index.php?option=com_content&view=article&id=130:paul-a-vanessa-willmott&catid=36:full-time-evangelists&Itemid=56&authid=91 [L]

 

Gave me a 500 internal server error - could it be that I'm testing on a subdomain before going live?

Link to comment
Share on other sites

Are you looking for a rewrite or a redirect?

 

I think that you may need to use the QSA flag to append your new query to the old query.

 

That space between the carat and the willmott is not good.

 

If that doesn't work, check in your error logs (found in cpanel, or wherever you keep them) for a clue.

 

for rewrite:


RewriteRule ^willmott index.php?option=com_content&view=article&id=130:paul-a-vanessa-willmott&catid=36:full-time-evangelists&Itemid=56&authid=91 [L,QSA,R]

 

for redirect just remove the R flag:


RewriteRule ^willmott index.php?option=com_content&view=article&id=130:paul-a-vanessa-willmott&catid=36:full-time-evangelists&Itemid=56&authid=91 [L,QSA]

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.