Markup from hell
A collection of bad practices in HTML, copied from real websites.
#5 button-like-link
submitted on by Vadimskip code sample<a href="#form" role="button" aria-haspopup="true"> Register </a>
#4 link-also-button
submitted on by Hiddeskip code sample<a href="https://example.com">
<button>Example</button>
</a>#3 image-buttons
submitted on by Manuelskip code sample<img src="/images/edit.gif" onclick="openEditDialog(123)">
<img src="/images/delete.gif" onclick="openDeleteDialog(123)">#2 div with button role
submitted on by Scheppskip code sample<div tabindex="-1">
<div role="button">
<svg width="28" height="24"> … </svg>
</div>
</div>#1 button disguised as a link
submitted on by Manuelskip code sample<button role="link" title="Name of website" tabindex="0">
<img alt="Name of website" src="logo.jpg" title="Name of website">
</button>