Forum Moderators: mack

Message Too Old, No Replies

Making scripted URL's shorter.

         

nanko

6:51 pm on Mar 18, 2005 (gmt 0)

10+ Year Member



I have a url that looks like-
[somesite.com...]

How can I create a url pointer that points to above location. for example simple pointer can be
[somesite.com...]

kodaks

7:13 pm on Mar 18, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



This may help:
[webmasterworld.com...]

wheel

6:15 pm on Mar 20, 2005 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



You probably don't want to use meta tags, but apache redirect instead.

We set up aphp error document in apache that deciphers pages. So in our apache config I've got a line like:
ErrorDocument 404 redirect.php
which says if it can't find page 'abc', then run redirect.php. Redirect.php deciphers the abc and serves the correct page.

Alternatively, you can probably do a complete rewrite (mapping 'abc' to the long filename) using regular expressions right in the Apache config file. This would take some research on your part I think. But it may be a better way than what I've suggested (not sure if there are implications in using a 404 redirect, but hey, it's working for me).