Forum Moderators: open

Message Too Old, No Replies

Redirecting a url to a shorter one for an ISBN number

         

wintercornuk

12:14 pm on Oct 18, 2004 (gmt 0)

10+ Year Member



My site has a long url for the many books on it.
viz:

The original product url would be [example.com...] which is too long.

The shorter version would be [example.com...] which would divert to the correct url.

This means that all products with an isbn could be easily found this way and all products would have a permanent, easy link.

I imagine it would involve having some kind of script in /isbn to convert and redirect.

Anyone got any ideas about how this could be achieved? I need some way of getting the ISBN from the first url and passing it to the second url.

[edited by: Xoc at 4:09 pm (utc) on Oct. 18, 2004]
[edit reason] changed to use example.com [/edit]

wintercornuk

12:37 pm on Oct 18, 2004 (gmt 0)

10+ Year Member



OK, I've almost worked this out by trial and lots of error, except for one thing:

<%
URL="http://www.example.com/"
fullurl="search.asp?searchbox3=" & server.URLencode("XXX")
response.redirect URL & fullurl
%>

I need to get the ISBN number typed in and replace the XXX with it. Any ideas on how this can be done?

[edited by: Xoc at 4:10 pm (utc) on Oct. 18, 2004]
[edit reason] changed to use example.com [/edit]