In the past, you would use <a name="example">
to create an anchor which you could jump to by adding #example
to the url.
However, this is being removed in HTML 5, with the "official" alternative being to use id
instead.
This is not acceptable when dealing with user-generated content, since it could interfere with other elements on the page. With name
, the worst that will happen is the link won't work, but conflicting id
s could break styles and scripts as well.
Is there some other way to do this?