HTML用ひながた > javascript 戻るボタン

Javascriptのhistory.back機能による戻るボタンです。
ブラウザの戻ると同じ働きをします。

実行例 (フォームタグの場合)

ソース  (フォームタグの場合)
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS">
<title>戻るボタン HTML用ひながた -ahref.org-</title>
</head>
<body bgcolor="white">
<form>
<INPUT type="button" onClick='history.back();' value="戻る">
</form>
</body>
</html>

実行例 (リンクタグ:Aタグの場合)

戻る

ソース(リンクタグ:Aタグの場合)
<html>
<head>
<meta http-equiv="content-type" content="text/html;charset=x-sjis">
<title>戻るボタン HTML用ひながた -ahref.org-</title>
</head>
<body bgcolor="white">
<a href="javascript:history.back();">戻る</a>
</body>
</html>