encoding a backlink into a php script

Discussion in 'Programming' started by nsmchris, Feb 27, 2008.

  1. #1
    I'm working on a php script that I plan on giving away for free. Although it would be free, I'd require a backlink. So is there anyway to encode a backlink into the script so that it is hard to find/remove. I'd also want the link to "follow", so using encoded javascript wouldn't work.
     
    nsmchris, Feb 27, 2008 IP
  2. redwall_hp

    redwall_hp Peon

    Messages:
    9
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #2
    I can't think of a foolproof method, but you could just make it real hard.

    You could just go the spaghetti-code route and do something like this:

    function bl1() {
    echo "<a href='";
    bl2();
    }
    function bl2() {
    echo "http://www.my";
    bl3();
    }
    function bl3() {
    echo "domain.";
    bl4()
    }
    function bl4() {
    echo "com'>This scr";
    bl5();
    }
    function bl5() {
    echo "ipt provided";
    }

    etc etc. Sprinkle the functions throughout your (hopefully long) script. By breaking up the echoed string, it makes it near impossible to grep though, looking for the code to remove.

    As I said before, its not foolproof. My recommendation: Don't bother. Just ask people nicely not to remove the link, and accept that some people will.
     
    redwall_hp, Feb 27, 2008 IP