// add edit link to menu
var pagebody = document.getElementsByClassName('static')[0];
if (pagebody) {
- var editlink = document.createElement('a');
- editlink.style.cursor = 'pointer';
- editlink.appendChild(document.createTextNode('Wijzig'));
- editlink.href = '#edit';
+ var editlink = document.querySelector('a[href="#edit"]');
editlink.onclick = function (e) {
editlink.style.fontWeight = 'bold';
editlink.href = '';
if (window.location.hash == '#edit') {
editlink.onclick();
}
- document.querySelector('header ul').appendChild(editlink);
}