diff options
| author | s1n <[email protected]> | 2020-01-28 14:46:42 -0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2020-01-28 14:46:42 -0800 |
| commit | 12565cca2e43049882691ab6130786fa86e4a9e1 (patch) | |
| tree | 510c1c000ba322e9f16e09e3f5fa37db0e8a1e94 /cs2-simple-website/js | |
| parent | Initial commit (diff) | |
| download | cs2-12565cca2e43049882691ab6130786fa86e4a9e1.tar.xz cs2-12565cca2e43049882691ab6130786fa86e4a9e1.zip | |
Add files via upload
Diffstat (limited to 'cs2-simple-website/js')
| -rw-r--r-- | cs2-simple-website/js/main.js | 14 | ||||
| -rw-r--r-- | cs2-simple-website/js/redirect-to-home.js | 1 |
2 files changed, 15 insertions, 0 deletions
diff --git a/cs2-simple-website/js/main.js b/cs2-simple-website/js/main.js new file mode 100644 index 0000000..0150af1 --- /dev/null +++ b/cs2-simple-website/js/main.js @@ -0,0 +1,14 @@ +var space = " ";
+var speed = "60";
+var pos = 0;
+var msg = "// Hom.e "; /*Enter the scrolling title as the msg variable's value.*/
+
+function Scroll() {
+ document.title = msg.substring(pos, msg.length) + space + msg.substring(0, pos);
+ pos++;
+ if (pos > msg.length) pos = 0;
+ window.setTimeout("Scroll()", speed);
+}
+Scroll();
+
+// Copyied from my GitHub repo: https://github.com/8cy/scrolling-html-title/blob/master/docs/js/main.js
\ No newline at end of file diff --git a/cs2-simple-website/js/redirect-to-home.js b/cs2-simple-website/js/redirect-to-home.js new file mode 100644 index 0000000..70666e8 --- /dev/null +++ b/cs2-simple-website/js/redirect-to-home.js @@ -0,0 +1 @@ +document.location = "/cs2-simple-website/home/" |