SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Enthusiast
    Join Date
    Oct 2008
    Posts
    96
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    anchor tags not working

    Hello.

    I've desiged a site using an apple style slider and my client wants each item to link to the item on the page rather than just the top of the page.

    They work fine if the item is on the page we're viewing but not if its on a different page. Does any one have any ideas?

    Link

    Many thanks!

  2. #2
    Programming Since 1978 silver trophybronze trophy felgall's Avatar
    Join Date
    Sep 2005
    Location
    Sydney, NSW, Australia
    Posts
    16,869
    Mentioned
    25 Post(s)
    Tagged
    1 Thread(s)
    With the following in your page:

    <div class="productdiv" id="undersink">

    You reference it as <a href="#undersink"> from the same page or as <a href="products_house.html#undersink"> from other pages.

    You don't need the separate <a name="undersink" id="undersink"> tag unless you still need to support Netscape 4. Just put the id in the <div>
    Stephen J Chapman

    javascriptexample.net, Book Reviews, follow me on Twitter
    HTML Help, CSS Help, JavaScript Help, PHP/mySQL Help, blog
    <input name="html5" type="text" required pattern="^$">


Bookmarks

Posting Permissions

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