From 18bef0f7bc7c2f71d964993a0b2268edba46eb0b Mon Sep 17 00:00:00 2001 From: mirivlad Date: Thu, 17 Aug 2023 22:31:05 +0800 Subject: [PATCH] Change html template to generate page from php --- assets/js/script.js | 11 ++-- index.php | 83 +++++++++++++++++++++++++++++ quotes.php | 42 +++++++++++++++ vars.php | 125 ++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 256 insertions(+), 5 deletions(-) create mode 100644 index.php create mode 100644 quotes.php create mode 100644 vars.php diff --git a/assets/js/script.js b/assets/js/script.js index 304b138..43588b4 100644 --- a/assets/js/script.js +++ b/assets/js/script.js @@ -24,21 +24,21 @@ function startTime() { day: "numeric" } - var date = currentDate.toLocaleDateString("en-GB", dateOptions); + var date = currentDate.toLocaleDateString("ru-RU", dateOptions); document.getElementById("header-date").innerHTML = date; var time = setTimeout(function(){ startTime() }, 60000); } // You can add your own random quotes and stuff here -const quotes = [ +/* const quotes = [ 'Hello, world...', 'Goodbye world sudo rm -rf *', 'This is a random quote' -]; -document.getElementById("header-quote").innerText = quotes[ +]; */ +/* document.getElementById("header-quote").innerText = quotes[ Math.floor(Math.random() * quotes.length) -]; +]; */ document.addEventListener('click', function (event) { @@ -66,6 +66,7 @@ function engines () { s: ['https://stackoverflow.com/search?q=', 'Stackoverflow'], a: ['https://web.archive.org/web/*/', 'Archive'], w: ['https://en.wikipedia.org/w/index.php?search=', 'Wikipedia'], + ya: ['https://yandex.ru/search/?text=', 'Yandex'], }; } diff --git a/index.php b/index.php new file mode 100644 index 0000000..d082143 --- /dev/null +++ b/index.php @@ -0,0 +1,83 @@ + + + + + + New Tab + + + + + + + + + +
+ +
+ + +
+ +
+ + + \ No newline at end of file diff --git a/quotes.php b/quotes.php new file mode 100644 index 0000000..a8fac5a --- /dev/null +++ b/quotes.php @@ -0,0 +1,42 @@ + \ No newline at end of file diff --git a/vars.php b/vars.php new file mode 100644 index 0000000..d8b1fae --- /dev/null +++ b/vars.php @@ -0,0 +1,125 @@ + + [ + [ + "url"=>"https://mirv.top/", + "name"=>"MIRV TOP", + "desc"=>"My ugly blog", + "icon"=>"mdi:wordpress" + ], + [ + "url"=>"https://wiki.mirv.top/", + "name"=>"Записнушка", + "desc"=>"Склерозник", + "icon"=>"mdi:notebook-outline" + ], + [ + "url"=>"https://rss.mirv.top/", + "name"=>"RSS News", + "desc"=>"My news feeds", + "icon"=>"mdi:rss" + ], + [ + "url"=>"https://git.mirv.top/", + "name"=>"GIT", + "desc"=>"Selfhosted git repo", + "icon"=>"simple-icons:gitea" + ], + [ + "url"=>"https://mon.mirv.top/", + "name"=>"Zabbix", + "desc"=>"Selfhosted monitoring system", + "icon"=>"carbon:cloud-monitoring" + ], + [ + "url"=>"https://up.mirv.top/", + "name"=>"Uptime", + "desc"=>"Selfhosted monitoring system", + "icon"=>"simple-icons:uptimekuma" + ], + [ + "url"=>"https://ha.mirv.top/", + "name"=>"Home Assistant", + "desc"=>"My self-AI home", + "icon"=>"mdi:home-assistant" + ], + [ + "url"=>"https://next.mirv.top/", + "name"=>"NextCloud", + "desc"=>"My garbage storage", + "icon"=>"simple-icons:nextcloud" + ], + [ + "url"=>"https://mine.mirv.top/", + "name"=>"MineCraft", + "desc"=>"Sweet Home", + "icon"=>"mdi:minecraft" + ], + [ + "url"=>"http://mine.mirv.top:8123/", + "name"=>"MineCraft Map", + "desc"=>"Map for MIRV Minecraft Server", + "icon"=>"mdi:map" + ], + [ + "url"=>"http://192.168.1.50/", + "name"=>"GAGARIN", + "desc"=>"Mainsail interface for Klipper", + "icon"=>"mdi:printer-3d-nozzle-outline" + ], + ], + "link"=> + [ + "EMAIL"=> + [ + [ + "url"=>"https://mail.google.com/mail/u/0/#inbox", + "name"=>"Gmail" + ], + [ + "url"=>"https://mail.yandex.ru/", + "name"=>"Ya.Mail" + ], + ], + "СОЦСЕТЬ"=> + [ + [ + "url"=>"https://vk.com/", + "name"=>"VK" + ], + [ + "url"=>"https://ok.ru/", + "name"=>"OK" + ], + [ + "url"=>"https://youtube.com/", + "name"=>"Youtube" + ], + ], + "МЕДИА"=> + [ + [ + "url"=>"https://music.yandex.ru/", + "name"=>"Ya.Music" + ], + [ + "url"=>"https://hd.kinopoisk.ru/", + "name"=>"KinoPoisk" + ], + + ], + "3D"=> + [ + [ + "url"=>"https://www.thingiverse.com/", + "name"=>"Thingiverse" + ], + [ + "url"=>"https://www.printables.com/", + "name"=>"Printables" + ], + + ], + ], +]; \ No newline at end of file