<html>
<head>
<style>
:link, :visited
{
border:10px solid black;
color: green;
padding:5px;
text-decoration: none
}
body
{
margin:20px 0
}
</style>
</head>
<a id="link">This should have a 10px solid black border around it.</a>
<script>
document.body.offsetLeft
document.getElementById('link').href = '#top';
</script>
</html>