why use javascript outlinks or redirected/cloaked external hyperlinks?

Discussion in 'HTML & Website Design' started by kanter, Apr 7, 2009.

  1. #1
    seems like there are multiple uses for such a concept, but which ones are truly necessary and work well? and which are just wishful thinking? this issue is getting more popular for warez forums, external linking like on blogs, and affiliate link protection as well.

    possible benefits of using javascript outlinks and/or php redirect tools:

    - track clicks on outlinks
    - ease of change (you can simply update the destination URL without changing the internal redirect code)
    - protect affiliate codes from being hijacked or hiding destinations
    - shorter URLs with your domain in them... more attractive, more trustable
    - prevent google/bots from indexing or seeing your hyperlinks (less PR issues, avoid "closed circle" linking, and/or more privacy i.e. for warez sites)
    - allow destination page to display within your own "ad packed" frame or toolbar
    - strip http headers (i'm not sure this is possible with either method?)

    anyway what do you guys think? why do you use these methods? am i missing any?

    also, if warez sites decide to simply remove the href code and use plaintext hyperlinks, is this truly safe because google can still index such URLs...?

    does anyone recommend a slick php redirect script that can accomplish any or all of these goals?

    thanks!
     
    kanter, Apr 7, 2009 IP
  2. dlb

    dlb Member

    Messages:
    203
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    35
    #2
    Thats great but if someone isn't using JavaScript your site breaks down completely. There is nothing wrong with the good old href.
     
    dlb, Apr 7, 2009 IP
  3. kanter

    kanter Banned

    Messages:
    72
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    i'm not sure if this is a serious post or not... 99% of users have javascript. your reponse isn't even relevant to my questions... :confused:
     
    kanter, Apr 7, 2009 IP
  4. meannn

    meannn Peon

    Messages:
    255
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #4
    That is just really nice.
     
    meannn, Apr 14, 2009 IP
  5. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,999
    Best Answers:
    253
    Trophy Points:
    515
    #5
    Funny, I was thinking the same thing about yours. Scripting for things that don't NEED scripting usually amounts to little more than a complete accessability /FAIL/.

    GOOD scripts and good web design in general should ALWAYS have fallbacks for if the 'gee ain't it neat' bullshit isn't present. That means javascript off, images off and even CSS off.

    It sounds like you are suggesting trying to game the system, which is the type of back hat asshattery that sooner or later always results in sites getting slapped down/banned from search engines.
     
    deathshadow, Apr 14, 2009 IP
  6. kanter

    kanter Banned

    Messages:
    72
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #6
    @deathshadow, you apparently aren't familiar with the worlds of "nofollow" and affiliate programs.

    even matt cuts from google endorses using javascript for these purposes... so your response isn't helpful.

    if you want to get up on a soapbox, then go elsewhere and please stop thread crapping.
     
    kanter, Apr 14, 2009 IP
  7. onehundredandtwo

    onehundredandtwo Guest

    Messages:
    56
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Bots like Googlebot may eventually be able to process scripts like JavaScript, especially with the emergence of AJAX. Using JavaScript for URLs may be a temporary solution for your indexing problems bot this will change.

    I'm not really sure about the PHP redirect, if it is a permanent redirect then Googlebot will follow it anyway, I'm not really sure about the temporary redirect though.

    In my opinion it would be better to stick with rel="nofollow" and robots.txt.
     
    onehundredandtwo, Apr 14, 2009 IP
  8. wd_2k6

    wd_2k6 Peon

    Messages:
    1,740
    Likes Received:
    54
    Best Answers:
    0
    Trophy Points:
    0
    #8
    There is no real need to use JS for links, or at least have a fall back as deathshadow says. All the reasons mentioned in the OP are for disliked practices, e.g frames and so on, which p*ss the average user off.

    As for not having a fallback, non-JS users have no way of clicking this link. For example I think I was browsing MySpace using my PS3 browser doing some plain tests, and had no real way of navigating through pages.

    The only other reason as deathshadow suggested is if you want to try and alter the way the SE judges your website. While I would advocate this in very select circumstances for SEO needs it rarley needs to be used. For example if a client wishes to preserve his so called "Pr-Juice", but this may be considered blackhat.

    JS annoys me greater and greater as the days pass, I might take the action of blocking it. Only thing I really need is Cookies I suppose + half of them are junk!
     
    wd_2k6, Apr 14, 2009 IP
  9. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,999
    Best Answers:
    253
    Trophy Points:
    515
    #9
    Which is the best approach since it works 99% of the time unless you are dealing with some sleazeball hacker trying to hijack your links (in which case a script is going to stop them for all of five seconds)

    Besides, go ahead and script them - then run it past a section 508 validator and read the WCAG.

    Oh, and if you are in the UK, enjoy your fines for violating the DDA.

    In general you will find asking about this in a HTML design area that you will get the same response you have gotten so far from dlb, onehundredandtwo, wd2k6 and myself - LEGITIMATE developers do not resort to that sort of sleazeball chicanery. You want people that are willing to try and use sleazeball tricks go try the SEO area or one of the advertising forums since that's usually filled with plenty of sleazeball scam artists and nubes believing the get rich quick nonsense - just steer clear of the handful of legitimate businessmen in there (Dan Schulz comes to mind), they'll rip you a bigger hole on that than we did.

    Of course you mentioned warez sites, which automaticallly means you are dealing with sleazeball advertising bullshit to go with the sleazeball illegal content wrapped in sleazeball markup.

    Yes, true... So true... I do believe I use that word far, far too often.
     
    deathshadow, Apr 14, 2009 IP
  10. onehundredandtwo

    onehundredandtwo Guest

    Messages:
    56
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #10
    Which is why you put all confidential files in one directory, and ban the entire directory through robots.txt. ;)
     
    onehundredandtwo, Apr 14, 2009 IP
  11. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,999
    Best Answers:
    253
    Trophy Points:
    515
    #11
    Sleazeball hacker isn't going to HONOR a robots.txt - which is the problem with it. Robots.txt is NOT going to stop a script kiddie screwing around in BASH doing a WGET...

    See, robots and nofollow operate on the honor system. It is assumed that legitimate search engines will actually pay attention to that file and the nofollow links - but there is NOTHING preventing your average sleazeball hacker from saying "**** that" and ignoring them outright.

    Which is why you'll see people talking about the approach he mentioned - the problem is it's an accessability violation if you don't include a graceful fallback... but the graceful fallback defeats the point of using it.

    Though you can see he's talking about it for things like pagerank reasons as well - that's just trying to game the system and spending too much time worrying about search ratings - which probably means not enough time is spent on content of value people might actually want to visit. Pagerank is not the be-all end-all of a website nor is artificial search rankings - what's worth more, a PR6 website that serves 500K visits a month to 8K unique visitors, or a PR4 website that serves 100K visits a month to 80K unique visitors. One has content of value, the other has gone nuts on promotion and sleazy black hat SEO bull that amounts to little more than polishing a turd.
     
    deathshadow, Apr 14, 2009 IP
  12. dlb

    dlb Member

    Messages:
    203
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    35
    #12
    I was being serious. Everyone else has already re-inforced my reasoning as to why.
     
    dlb, Apr 22, 2009 IP
  13. Final Verdict

    Final Verdict Peon

    Messages:
    111
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #13
    This is a issue I've kicked around quite a few times, and always decide against the javascript menu. I like the look with using javascript and flash, but like stated above, the risk of visitors not being able to see it for not having the latest update or flash installed, I still feel whatever you want to accomplish is still capable with html and is the safe bet.
     
    Final Verdict, Apr 22, 2009 IP
  14. mathew4847

    mathew4847 Peon

    Messages:
    12
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #14
    Thank you kanter for youe informations
     
    mathew4847, Apr 22, 2009 IP
  15. shruchi nagar

    shruchi nagar Guest

    Messages:
    144
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #15
    Hi,
    In my opinion, JavaScript is more better than href, because this language is more reliable and most of the software developers use this. So I recommend you that use JavaScript. Anyway choice is yours.
     
    shruchi nagar, Apr 22, 2009 IP
  16. pitagora

    pitagora Peon

    Messages:
    247
    Likes Received:
    9
    Best Answers:
    0
    Trophy Points:
    0
    #16

    of course hackers don't honor robots.txt. The question is, what is preventing them from looking at your javascript to get the link? The effort is in no way greater. If I want a link I'll get it. You simply can't protect something you are sending to the browser anyway! Worse case scenario: the javascript is obfuscated and I'm too lazy to spend 10 mins on it to understand it, so I use any FF plugin that shows http requests (I personally use tamperdata for pentesting and firebug for development - any of these will do), click the link and just see where it sends me :p It will take me 5 seconds and NO thinking or skills.

    Do not rely on javascript for security. It wasn't made for that!

    First of all how can it be more reliable then a href if it only works with javascript on?

    Second: You are not designing for other developers but for users. I'm sorry to inform you but there are lots of users with javascript disabled or using the NoScript firefox extension. Don't use javascript unless you have to, and when you do make sure it degrades gracefully.
     
    pitagora, Apr 25, 2009 IP
  17. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,999
    Best Answers:
    253
    Trophy Points:
    515
    #17
    Heh, which is exactly what I meant with this:
     
    deathshadow, Apr 25, 2009 IP
    pitagora likes this.