diff options
| author | Aiden Woodruff <aiden.woodruff@gmail.com> | 2018-06-28 21:37:08 -0500 |
|---|---|---|
| committer | Aiden Woodruff <aiden.woodruff@gmail.com> | 2018-06-28 21:37:08 -0500 |
| commit | c8d0e69e0407b8638d888d3efb6742ddc5a3ed0c (patch) | |
| tree | c1b4bf2364bc56a264f5087b6a95f8b03d3ba8d2 | |
| parent | 36a93b28ac4d240f9a0ee8a2382a94c590adf7c3 (diff) | |
| download | sweeper-c8d0e69e0407b8638d888d3efb6742ddc5a3ed0c.tar.gz sweeper-c8d0e69e0407b8638d888d3efb6742ddc5a3ed0c.tar.bz2 sweeper-c8d0e69e0407b8638d888d3efb6742ddc5a3ed0c.zip | |
XHTML compliancy on sweeper.js, leaders.html, favicon works
Signed-off-by: Aiden Woodruff <aiden.woodruff@gmail.com>
| -rw-r--r-- | ChangeLog | 18 | ||||
| -rw-r--r-- | index.html | 1 | ||||
| -rw-r--r-- | leaders.html | 19 | ||||
| -rw-r--r-- | rules.html | 1 | ||||
| -rw-r--r-- | sweeper.js | 8 |
5 files changed, 33 insertions, 14 deletions
| @@ -2,7 +2,23 @@ | |||
| 2 | 2 | ||
| 3 | * index.html: Fixed meta with no close bracket. | 3 | * index.html: Fixed meta with no close bracket. |
| 4 | More XHTML compliant. | 4 | More XHTML compliant. |
| 5 | Favicon is ogimage.jpg | 5 | Favicon is favicon.png |
| 6 | og:image is ogimage.jpg | ||
| 7 | Shortened og:description | ||
| 8 | Rules is not collapsible iframe, but link. | ||
| 9 | Rules link is to right of title. | ||
| 10 | |||
| 11 | * rules.html: Changed to tutorial. | ||
| 12 | Written for short game. | ||
| 13 | Branch merged and deleted. | ||
| 14 | XHTML compaliant. | ||
| 15 | |||
| 16 | * favicon.ico, favicon.png: Added | ||
| 17 | |||
| 18 | * sweeper.js: Fixed some XHTML stuff. | ||
| 19 | Fixed h3 tag closed by br?? | ||
| 20 | |||
| 21 | * leaders.html: XHTML compliancy. | ||
| 6 | 22 | ||
| 7 | 2018-06-27 Aiden Woodruff <aiden.woodruff@gmail.com> | 23 | 2018-06-27 Aiden Woodruff <aiden.woodruff@gmail.com> |
| 8 | 24 | ||
| @@ -13,6 +13,7 @@ | |||
| 13 | <meta http-equiv="Pragma" content="no-cache" /> | 13 | <meta http-equiv="Pragma" content="no-cache" /> |
| 14 | <meta http-equiv="Expires" content="-1" /> | 14 | <meta http-equiv="Expires" content="-1" /> |
| 15 | <title>Minesweeper</title> | 15 | <title>Minesweeper</title> |
| 16 | <link type="image/png" rel="shortcut icon" href="favicon.png" /> | ||
| 16 | <link type="text/css" rel="stylesheet" href="styles.css" /> | 17 | <link type="text/css" rel="stylesheet" href="styles.css" /> |
| 17 | <script type="application/javascript" src="http-get.js"></script> | 18 | <script type="application/javascript" src="http-get.js"></script> |
| 18 | <script type="application/javascript" src="sweeper.js"></script> | 19 | <script type="application/javascript" src="sweeper.js"></script> |
diff --git a/leaders.html b/leaders.html index 3479fca..39369ea 100644 --- a/leaders.html +++ b/leaders.html | |||
| @@ -1,13 +1,14 @@ | |||
| 1 | <!DOCTYPE html> | 1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> |
| 2 | <html> | 2 | <html xmlns="http://www.w3.org/1999/xhtml"> |
| 3 | <head> | 3 | <head> |
| 4 | <meta charset="UTF-8"> | 4 | <meta charset="UTF-8" /> |
| 5 | <meta name="author" content="Aiden Woodruff"> | 5 | <meta name="author" content="Aiden Woodruff" /> |
| 6 | <meta name="description" content="Minesweeper Leaderboard"> | 6 | <meta name="description" content="Minesweeper Leaderboard" /> |
| 7 | <meta name="keywords" content="minesweeper, leaderboard"> | 7 | <meta name="keywords" content="minesweeper, leaderboard" /> |
| 8 | <meta http-equiv="Pragma" content="no-cache"> | 8 | <meta http-equiv="Pragma" content="no-cache" /> |
| 9 | <meta http-equiv="Expires" content="-1"> | 9 | <meta http-equiv="Expires" content="-1" /> |
| 10 | <link rel="stylesheet" type="text/css" href="styles.css"> | 10 | <link type="image/png" rel="shortcut icon" href="favicon.png" /> |
| 11 | <link rel="stylesheet" type="text/css" href="styles.css" /> | ||
| 11 | <title>Leaderboard</title> | 12 | <title>Leaderboard</title> |
| 12 | <script type="application/javascript" src="leaders.js"> | 13 | <script type="application/javascript" src="leaders.js"> |
| 13 | </script> | 14 | </script> |
| @@ -3,6 +3,7 @@ | |||
| 3 | <head> | 3 | <head> |
| 4 | <meta charset="utf-8" /> | 4 | <meta charset="utf-8" /> |
| 5 | <title>Rules of Minesweeper</title> | 5 | <title>Rules of Minesweeper</title> |
| 6 | <link type="image/png" rel="shortcut icon" href="favicon.png" /> | ||
| 6 | <link rel="stylesheet" href="styles.css" /> | 7 | <link rel="stylesheet" href="styles.css" /> |
| 7 | <style type="text/css"> | 8 | <style type="text/css"> |
| 8 | div.exboard { | 9 | div.exboard { |
| @@ -102,7 +102,7 @@ function win () { | |||
| 102 | } | 102 | } |
| 103 | window.clearInterval(timer); | 103 | window.clearInterval(timer); |
| 104 | document.getElementById("board").innerHTML += ""; | 104 | document.getElementById("board").innerHTML += ""; |
| 105 | document.getElementById("end").innerHTML = "<br><h3>Congratulations! You win! :)</h3>\nName: <input id='name' type='text'><br><input id='leaderboard' type='button' value='Push to leaderboard'>"; | 105 | document.getElementById("end").innerHTML = "<br /><h3>Congratulations! You win! :)</h3>\nName: <input id='name' type='text' /><br /><input id='leaderboard' type='button' value='Push to leaderboard' />"; |
| 106 | document.getElementById("leaderboard").onclick = update_leaderboard; | 106 | document.getElementById("leaderboard").onclick = update_leaderboard; |
| 107 | document.getElementById("name").onkeypress = function (e) { | 107 | document.getElementById("name").onkeypress = function (e) { |
| 108 | if (e.key === "Enter") { | 108 | if (e.key === "Enter") { |
| @@ -116,7 +116,7 @@ function win () { | |||
| 116 | function lose () { | 116 | function lose () { |
| 117 | window.clearInterval(timer); | 117 | window.clearInterval(timer); |
| 118 | document.getElementById("board").innerHTML += ""; | 118 | document.getElementById("board").innerHTML += ""; |
| 119 | document.getElementById("end").innerHTML = "<br><h3>I am so sorry. You have lost. :(</br>"; | 119 | document.getElementById("end").innerHTML = "<br /><h3>I am so sorry. You have lost. :(</h3>"; |
| 120 | } | 120 | } |
| 121 | 121 | ||
| 122 | function count3BV () { | 122 | function count3BV () { |
| @@ -480,7 +480,7 @@ window.onload = function () { | |||
| 480 | item.id = "click_type_form"; | 480 | item.id = "click_type_form"; |
| 481 | item.style.border = "1px solid black"; | 481 | item.style.border = "1px solid black"; |
| 482 | item.style.display = "inline-block"; | 482 | item.style.display = "inline-block"; |
| 483 | item.innerHTML = "<h3 style='display:inline'>Click Mode: </h3><input type='radio' name='clicktype' id='right' value='right' checked><label for='right'>Reveal</label><input type='radio' name='clicktype' id='left' value='left'><label for='left'>Flag</label>"; | 483 | item.innerHTML = "<h3 style='display:inline'>Click Mode: </h3><input type='radio' name='clicktype' id='right' value='right' checked='checked' /><label for='right'>Reveal</label><input type='radio' name='clicktype' id='left' value='left' /><label for='left'>Flag</label>"; |
| 484 | document.getElementById("content").appendChild(item); | 484 | document.getElementById("content").appendChild(item); |
| 485 | 485 | ||
| 486 | // Add some spacing | 486 | // Add some spacing |
| @@ -512,7 +512,7 @@ window.onload = function () { | |||
| 512 | // restart form | 512 | // restart form |
| 513 | item = document.createElement("form"); | 513 | item = document.createElement("form"); |
| 514 | item.method = "get"; | 514 | item.method = "get"; |
| 515 | item.innerHTML = "Width: <input type='number' placeholder='10' name='width'>Height: <input placeholder='10' type='number' name='height'>Mines: <input type='number' name='mines'><br><input type='submit' value='New Game'>"; | 515 | item.innerHTML = "Width: <input type='number' placeholder='10' name='width' />Height: <input placeholder='10' type='number' name='height' />Mines: <input type='number' name='mines'><br><input type='submit' value='New Game'>"; |
| 516 | document.getElementById("content").appendChild(item); | 516 | document.getElementById("content").appendChild(item); |
| 517 | } | 517 | } |
| 518 | if (width * height > 5000) { | 518 | if (width * height > 5000) { |
