Need help with external link script

Discussion in 'Programming' started by webmasterplace, Nov 3, 2007.

  1. #1
    Hi,

    I've made a redirect script for my forum. When someone posts a link in my forum it will change the link to: http://www.modbase.be/out.php?url=http://thelink.com .There are some things that need to be changed, but I need some help with it.

    You can test the script here:
    http://www.modbase.be/out.php?url=http://forums.digitalpoint.com

    This will add a frame above the website.

    What's need to be changed:
    - When there is no http:// in front of the url e.g.: out.php?url=www.google.com then the script must automaticly add the http:// in front of it.
    - When someone posts a link which contains my domain, the script must not be used. E.g.: Someone posts: http://www.modbase.be/tutorials.php in the forum, the link must be intact and not http://www.modbase.be/out.php?url=http://www.modbase.be/tutorials.php

    So the script must only be used when it's an external link.

    If you can help me with this, PM me and I'll give you the details about the script and how it works.

    Thanks!

    @MODS: Maybe this thread should be better in the PHP subforum.
    Sorry
     
    webmasterplace, Nov 3, 2007 IP