Difference between title and name in html href element -


in href in html, whats difference between using

<a href="http://www.somesite.com/" name="the name"> 

and

<a href="http://www.somesite.com/" title="the name"> 

is there advantage using 1 on other?

thanks

look in spec, or better yet resource condenses spec bit. (and, spec if isn't enough.)

title   text    specifies information element 

http://www.w3schools.com/tags/tag_a.asp

the name attribute specifies name of anchor.

the name attribute used create bookmark inside document.

the href or name attribute must present in tag

http://www.w3schools.com/tags/att_a_name.asp

so, name of anchor used links exampledomain.com/index.php#some_section, bring anchor focus on page.

many modern browsers display title attribute in tooltip when hovering on link. it's useful screen readers , such.


Comments

Popular posts from this blog

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -

c# - DataTable to EnumerableRowCollection -