Results 1 to 9 of 9

Thread: Affiliate links

  1. #1
    Join Date
    Mar 2006
    Posts
    13

    Question Affiliate links

    I have tried several ways to hide affiliate links in indexu but i cant seem to get it to work how i want?

    I setup a custom field for affiliate_url
    But if i use this in details and rows, whenever there is not an affiliate link, the link don't work?

    It is like a need an IF statement or something.
    Here is what i tried:
    <a href="<%$url%>" onclick="location.href='<%$affiliate_url%>';return false;">Visit</a>

    this works great if all links where affiliate links.
    Wont work for non-affiliate links.

    Any help would be much appreciated.
    Last edited by cheetah; 07-15-2007 at 03:13 PM.

  2. #2
    Join Date
    Jun 2002
    Location
    Winnipeg Canada
    Posts
    4,913

    Default

    Do you really need to hide the affiliate links? Most people don't know they are affiliate links and will click anyways.

    One thing you can do is just change the following to not show the URL in detail_link.html

    <label for="url">Url</label>
    <span class="text"><a href="<%$url%>" name="link_<%$link_id%>"><%$url%></a></span>

    Change to

    <label for="url">Url</label>
    <span class="text"><a href="<%$url%>" name="link_<%$link_id%>"><%$title%></a></span>

    That will show the title, instead of the URL. Simple but effective.

  3. #3
    Join Date
    Mar 2006
    Posts
    13

    Default

    Yes, i would like to show the fake url instead of the affiliate url but the problem is not all the links are affiliate links.

    There has to be a way to do this?

    So i need like:

    IF affiliate_url the do this special action
    Else
    Do regular link action

    Not very good at php so if you can help i would appreciate it.

    There are three place to change the links
    detail
    rows
    and link title

  4. #4
    Join Date
    Mar 2006
    Posts
    13

    Default

    No ideas?

  5. #5
    Join Date
    Nov 2004
    Posts
    1,822

    Default

    the answer was posted above...

    jsut change "url" to "title" in the link text...

    or do you want it to be hidden further? if you look at the svn version (nicecoder.com/svn) look at hte entry called "add go.php url masking script" and follow the code changes.

    Then you can change the "url" to read : go.php?id=12 and it will hide the url
    Main IndexU sites : | Campsite Directory | Tourist Guide | Places2B | AfterDirectory <-- Half price submission using coupon DP50 (from just $11 premium, and $10 basic permanent )

  6. #6
    Join Date
    Mar 2006
    Posts
    13

    Default

    Yes that is exactly waht i was looking for, it is like hotscript and others.

    One problem, i can't login to see the code?
    And is this the entry you were refering to?

    [496] 03/09/07 20:57:49 EST
    Add url masking script go.php?id=<%$link_id%>


    Also is svn future and past updates?

    Thanks for the help.

  7. #7
    Join Date
    Mar 2006
    Posts
    13

    Default

    OK, i got logged in but there is no code to add under

    http://nicecoder.com/svn/index.php?act=changeset&id=496

    What exactly was the change to use link_id instead of url's


    Thanks

  8. #8
    Join Date
    Nov 2004
    Posts
    1,822

    Default

    its a file thats been added, not code change, just download the nightly build file, and upload go.php and your done
    Main IndexU sites : | Campsite Directory | Tourist Guide | Places2B | AfterDirectory <-- Half price submission using coupon DP50 (from just $11 premium, and $10 basic permanent )

  9. #9
    Join Date
    Mar 2006
    Posts
    13

    Default

    The file looks the same as the one i already had, and after uploading anyway nothing has changed, still points to the url instead of link_id??

    I also updated all links and still no change.

    Any help would be appreciated.

Similar Threads

  1. Creating Affiliate Links
    By angie in forum v5.x
    Replies: 2
    Last Post: 09-15-2006, 12:58 PM
  2. php affiliate code not passing
    By vittle in forum v5.x
    Replies: 1
    Last Post: 02-16-2006, 05:52 PM
  3. Affiliate Program?
    By retrolyte in forum Pre-Sales Questions
    Replies: 0
    Last Post: 12-10-2005, 10:21 PM
  4. Presales question - Affiliate links
    By sleepy in forum Pre-Sales Questions
    Replies: 2
    Last Post: 10-27-2003, 08:33 AM
  5. Affiliate Section Needed
    By bgray in forum v3.2
    Replies: 2
    Last Post: 06-25-2003, 08:26 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •