File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11<!DOCTYPE html>
2- < html manifest ="snake.appcache ">
2+ <!--< html manifest="snake.appcache">-- >
33< head >
44<!--
55
66JavaScript Snake
77By Patrick Gillespie
88http://patorjk.com/games/snake
99
10- Soure code is available here: https://github.com/patorjk/JavaScript-Snake
10+ Source code is available here: https://github.com/patorjk/JavaScript-Snake
1111
1212-->
1313 < title > JavaScript Snake</ title >
14- < link rel ="stylesheet " type ="text/css " href ="./css/snake.css " />
15-
16- < script type ="text/javascript ">
14+ < link rel =stylesheet id =style type =text/css href =./css/main-snake.css />
15+ < button onclick =getTheme() > Click to use this theme.</ button >
16+ < select id ="select ">
17+ < option > Dark Theme</ option >
18+ </ select >
19+ < script src ="//code.jquery.com/jquery-1.10.2.js "> </ script >
20+ < script src ="//code.jquery.com/ui/1.11.4/jquery-ui.js "> </ script >
21+ < script >
22+ function getTheme ( ) {
23+ function changeTheme ( Theme ) {
24+ document . getElementById ( 'style' ) . setAttribute ( 'href' , Theme ) ;
25+ }
26+ var index = document . getElementById ( "select" ) . selectedIndex ;
27+ switch ( index ) {
28+ case 0 :
29+ changeTheme ( 'css/dark-snake.css' ) ;
30+ }
31+ }
1732if ( navigator . onLine && window . location . hostname === 'patorjk.com' ) {
1833 var _gaq = _gaq || [ ] ;
1934 _gaq . push ( [ '_setAccount' , 'UA-3312460-1' ] ) ;
3752 fullScreen : true
3853 } ) ;
3954 </ script >
55+ < div id ="high-score-dialog "> </ div >
4056</ body >
41- </ html >
57+ </ html>
You can’t perform that action at this time.
0 commit comments