Frage

Trying to create my own Back/Forward buttons in xul.

My Code:

<label value=" ❀ Back " id="back_button" style="-moz-border-radius: 20px; -webkit-border-radius: 20px; -khtml-border-radius: 20px; border-radius: 20px;background:#C93E1D; width:100px; color:white;" onclick="history.go(-1);"></label>

Also tried history.back() onclick of xul button. But nothing happened.

<button label="back" oncommand="history.back();"/>
War es hilfreich?

Lösung

This works for me:

document.getElementById("main-browser").webNavigation.goBack();
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top