wilslm
asked on
#
what does # mean?
i saw the syntax --> <a href="page.html#layer">
Thank you guys
i saw the syntax --> <a href="page.html#layer">
Thank you guys
Just like below
http://www.nus.edu.sg/gem/about_faq.htm#21
http://www.nus.edu.sg/gem/about_faq.htm#21
It is used to have links on the same page. So somewhere in the source of page.html is a
<a name="layer"></a>
And by clicking on the link "page.html#layer" you will have that exact place on the page in your browser, not just the top of that page.
<a name="layer"></a>
And by clicking on the link "page.html#layer" you will have that exact place on the page in your browser, not just the top of that page.
If you want to create links within a page you can accomplish it by using <a href="page.html#layer">
A small example for you to make it understand better
<a href="page.html#book1">Go to book 1 section</a> : When you click this link it will take you to a book 1 section on page even if its all the way on the bottom of the page
<a href="page.html#book2">Go to book 2 section</a>
<a href="page.html#book3">Go to book 3 section</a>
<a name="book1">Book 1 section</a>
<a name="book2">Book 1 section</a>
<a name="book3">Book 1 section</a>
A small example for you to make it understand better
<a href="page.html#book1">Go to book 1 section</a> : When you click this link it will take you to a book 1 section on page even if its all the way on the bottom of the page
<a href="page.html#book2">Go to book 2 section</a>
<a href="page.html#book3">Go to book 3 section</a>
<a name="book1">Book 1 section</a>
<a name="book2">Book 1 section</a>
<a name="book3">Book 1 section</a>
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
assuming Zonstar ;) forgot to return false on an accident
<p><a href="#" onclick="alert("Hi there!");return false;">Click here for a useless message</a>.</p>
<p><a href="#" onclick="alert("Hi there!");return false;">Click here for a useless message</a>.</p>
and used double quota's in a single quotas place
<p><a href="#" onclick="alert('Hi there!');return false;">Click here for a useless message</a>.</p>
<p><a href="#" onclick="alert('Hi there!');return false;">Click here for a useless message</a>.</p>
hongjun