#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2001
    Posts
    297
    Rep Power
    14

    How to make these links clickable using the <a> tag?


    In a url (http://www.smoothdivscroll.com/lab.html) I find around line 73-75 this piece of code:

    <fieldset class="subPanel">
    <legend></legend>
    <span id="startAutoScrolling">START</span> |
    <fieldset style="margin-top: 15px;">
    <legend>Set auto scrolling direction</legend>
    <span class="autoScrollingDirection" id="right">right</span> |
    <span class="autoScrollingDirection" id="left">left</span> |
    <span class="autoScrollingDirection" id="backandforth">backandforth</span>
    </fieldset>
    </fieldset>

    I would like to change the code so I can make three clickable links using the <a> tag around
    <span class="autoScrollingDirection" id="right">right</span>

    The strange thing is that in the url mentioned above "right", "left" and "backandforth" are clickable. But if I copy the code they are not clickable anymore.

    Can anyone help?

    Kippie
    Last edited by kippie; August 13th, 2012 at 02:43 PM.
  2. #2
  3. CSS & JS/DOM Adept
    Devshed Supreme Being (6500+ posts)

    Join Date
    Jul 2004
    Location
    USA (verifiably)
    Posts
    20,131
    Rep Power
    4304
    It must be using JavaScript. I would not recommend that you use that particular script though, because it may be as awful as the HTML it's used with.

    Just because you can make pretty much any element clickable, doesn't mean that you should. Links and buttons are the proper elements for such a user interaction.

    If you're using jQuery already, I recommend jCarousel Lite.
    Last edited by Kravvitz; August 13th, 2012 at 04:23 PM.
    Spreading knowledge, one newbie at a time.

    Check out my blog. | Learn CSS. | PHP includes | X/HTML Validator | CSS validator | Common CSS Mistakes | Common JS Mistakes

    Remember people spend most of their time on other people's sites (so don't violate web design conventions).
  4. #3
  5. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2012
    Posts
    8
    Rep Power
    0
    Originally Posted by Kravvitz
    It must be using JavaScript. I would not recommend that you use that particular script though, because it may be as awful as the HTML it's used with.

    Just because you can make pretty much any element clickable, doesn't mean that you should. Links and buttons are the proper elements for such a user interaction.
    Happy to see your helpful reply because also I have that kind of problem.Well you have shared much important thing and it will help to many other people.
    Last edited by Kravvitz; October 3rd, 2012 at 03:38 AM. Reason: fixed the quote tags

IMN logo majestic logo threadwatch logo seochat tools logo