You are here: Re: One time links / urls « PHP Programming Language « IT news, forums, messages
Re: One time links / urls

Posted by Jerry Stuckle on 05/19/07 02:39

2good2b@gmail.com wrote:
> On May 19, 3:26 am, Jerry Stuckle <jstuck...@attglobal.net> wrote:
>> 2goo...@gmail.com wrote:
>>> How do I create one time links such as in:
>>> http://www.tv-links.co.uk/link.do/1/1123/1699/14093/23781
>>> Thank you
>> That's not a one-time link.
>>
>> --
>> ==================
>> Remove the "x" from my email address
>> Jerry Stuckle
>> JDS Computer Training Corp.
>> jstuck...@attglobal.net
>> ==================
>
> Hi Jerry,
> I am sorry if I wasn't clear enough (I am not a native English
> speaker)
> I was refering to the link inside that page, i.e.
> http://www1.tv-links.co.uk/link.do/1/1123/1699/14093/23781/once/92c13de5a560befafbee63783cdc685826f7562
>
> The "92c13de5a560befafbee63783cdc685826f7562" part is the one-time
> part
> Thanks again
>

Well, I don't see a link like that in the page.

But how you do it - typically a combination of using Apache's
mod_rewrite and a database. Set your url rewrite commands in the your
..htaccess file (or httpd.conf if you have root access). Any request in
the xxx/once directory gets directed to a script, passing the long
alphanumeric string as a parameter.

Previously, before you displayed the link, you created an entry in your
database, using the long alphanumeric string and the real destination.
When the user requests this uri, mod_rewrite redirects the request to
your script. Your script then looks up the long alphanumeric string in
the database. If found, it serves the appropriate page. If not, it
redirects to the Not Found page.

Not that hard. Exact details on how to do it depend on the database and
programming language.

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@attglobal.net
==================

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация