PHP help needed please

by 2 replies
3
In a script I'm writing I have a list of Clickbank hoplinks. What I want to do is find out, within the running of the script, what the final destination url is of each hoplink.

In other words, follow the redirects to their final destination and report back the sales page URL.

Does anyone have any idea how I can achieve this?

Thanks,

Martin
#programming #needed #php
  • If I understand what you're asking correctly could you not store the link URLs in either a file or database and then query them.

    You could then use the header command to send the visitor to the page, e.g.

    header ('Location: http://www.clickbankhoplink etc/');

    Is this on the right track?

    Jonathan
  • I think you can probably get this information from the headers returned by fetching the page with cURL.

    PHP: cURL - Manual

Next Topics on Trending Feed

  • 3

    In a script I'm writing I have a list of Clickbank hoplinks. What I want to do is find out, within the running of the script, what the final destination url is of each hoplink. In other words, follow the redirects to their final destination and report back the sales page URL.