如果是一个页面出错了转到了另外一个页面的话:为按钮加个事件:history.go(-2);
如:
<input type="button" onclick="history.go(-1)" value="back">