Skip to content

Instantly share code, notes, and snippets.

@vaseker
Created June 28, 2016 10:45
Show Gist options
  • Save vaseker/552c27977e61e86201ccfc0a81561a93 to your computer and use it in GitHub Desktop.
Save vaseker/552c27977e61e86201ccfc0a81561a93 to your computer and use it in GitHub Desktop.
Anchor test
<!DOCTYPE html>
<html>
<head></head>
<body>
<script type="text/javascript">
var targets = '';
var menu = ''
for (var i = 0; i < 10; i++) {
var id = 'anc_' + i;
menu += '<li><a href="#' + id + '">' + id + '</a></li>';
targets += //'<a name="' + id + '"></a>' +
'<p id="' + id + '">\
<h3>' + id + '</h3>\
ogogo3ingqong owngp iw3j iugj u3ih293h 2h ngiu2n5 2\
irgniqunginhu2nh9 29 hj29 hj294-j h29 jh98j25 9jh 95jh92j 9hj 2jh j29 jh92j 9h2j 9jh2 -j 92-j\
2ij 9ij92j4h9-24jh92524jh94jh-942jh94jh249j24nnb924-9j5h9j2495hj9hj2-j294j95hj49-\
roijoqirjgoirpgjqioj gqrg qreoij goqiej goiqn goiqn goiqj gioqj iogqjiog jqoij gqo\
oqir goirjg qoijg poqej goqij goqerj goiqje oirjg oiqrej goirejg oqirej gqoj q gqeroi jgqoi\
</p>';
}
document.write('<ul>' + menu + '</ul>');
document.write(targets);
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment