The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

Adding a link to content on the same page (2 posts)

  1. tangerine3
    Posted 5 years ago #

    What code would i use if I wanted to click a line of text and it takes you to a heading on the same page.

    e.g., I want to click on "Business Hours" and it takes you to that heading down below on the same page. This is the code I have now but it is not working. It tries to take me to a page that isn't found.

    this is the heading at the top of the page
    <a href="Business Hours"><span style="color: #330099;">Business Hours</span></a>

    this is where i want it to take me
    <a name="Business Hours"><span style="color: #330099;">Business Hours</span></a>


  2. Maeve Lander
    Posted 5 years ago #

    This is called an Anchor. You will find heaps of tutorials online so check those out if you want a full tutorial. It looks like you're on the right track but just have your name attribute the wrong way round. It should look like this.

    The code you need for the heading will be:
    <a name="businesshours">Business Hours</a>

    You then need to use this code lower down the page where you want it to end up:
    <a href="#businesshours">Business Hours</a>

Topic Closed

This topic has been closed to new replies.

About this Topic