diff --git a/todo.txt b/todo.txt
deleted file mode 100644
index 5cf1f2d..0000000
--- a/todo.txt
+++ /dev/null
@@ -1,29 +0,0 @@
-DONE:
-- install php8.2-fpm nginx
-- make the nginx config
-
-create index.php
-- in it, you must be able to display the contents of the csv file in an array https://stackoverflow.com/questions/1269562/how-to-create-an-array-from-a-csv-file-using-php-and-the-fgetcsv-function
-
-- create the status.csv file with this syntax: [URL;NAME;CATEGORY;DESCRIPTION;STATUS;]
-
-- csv file updater in python ? and triggered by a cronjob ?
- https://docs.python.org/3/library/csv.html
- https://stackoverflow.com/questions/1949318/checking-if-a-website-is-up-via-python
- https://stackoverflow.com/questions/63970912/urllib-request-with-socks5-proxy
-
--from python, sort the CSV files based on the score value
-
--make the css to be dark background and light text (copy it from nowhere)
--make a header php page, containing the links ot the other status pages
--make a monero node checker page,
--make a nowhere dot moe service checker
-
--upload the sourcecode to gitea
- -> create README.md
-TODO:
- -> mention the sourcecode in the header
-- check for status 200s otherwise it might believe that a 502 is a valid status code
--
-
-
diff --git a/www/header.php b/www/header.php
index a08a96a..b6044c6 100644
--- a/www/header.php
+++ b/www/header.php
@@ -5,3 +5,70 @@
Update Frequency: every 3 hours
+
+\n\n"; //begin html table formatting
+if (($handle = fopen($csvfile, "r")) !== FALSE) {
+
+
+ while (($data = fgetcsv($handle, 1000, ",")) !== FALSE) {
+ $num = count($data);
+ //echo "" . $data[1] . "
";
+ //echo " $num fields in line $row:
\n";
+ $row++;
+ //echo $row;
+
+
+ if ( $row == "2") {
+ echo "Name | Score | |
";
+ }else{
+ for ($c=0; $c < $num; $c++) {
+ echo ""; // beging html table row
+ // if the row is the first one (name url status score) only display (Name Status Score):
+ // display the contents of a csv row
+ if ( $c == "1" ){
+ echo "" . ''; // display the link
+ echo $data[0] . " | "; // display the link title and close the a href and first cell, open the second cell
+ echo $data[3] . " | "; // display the status and close the second cell, open the third cell
+ echo $data[2] . " | \n"; // display the score and close the third cell
+ }
+ //if ($c == 2){
+ //}
+ }
+ }
+ echo "
"; // end html table row
+ }
+ echo "\n
";
+ fclose($handle);
+}
+
+}
+
+
+function DisplayCSVold($csvfile) {
+echo "\n\n";
+
+ // Open a file
+ $file = fopen($csvfile, "r");
+
+ // Fetching data from csv file row by row
+ while (($data = fgetcsv($file)) !== false) {
+
+ // HTML tag for placing in row format
+ echo "";
+ foreach ($data as $i) {
+ echo "" . htmlspecialchars($i)
+ . " | ";
+ }
+ echo "
\n";
+ }
+
+ // Closing the file
+ fclose($file);
+
+ echo "\n
";
+}
+?>
diff --git a/www/index.php b/www/index.php
index 43968a5..fd57dc5 100644
--- a/www/index.php
+++ b/www/index.php
@@ -22,83 +22,24 @@ require("header.php");
- \n\n";
-
- // Open a file
- $file = fopen("links/webring.csv", "r");
-
- // Fetching data from csv file row by row
- while (($data = fgetcsv($file)) !== false) {
-
- // HTML tag for placing in row format
- echo "";
- foreach ($data as $i) {
- echo "" . htmlspecialchars($i)
- . " | ";
- }
- echo "
\n";
- }
-
- // Closing the file
- fclose($file);
-
- echo "\n
";
- ?>
-
-
+
+
+
+
Onion Webring Instances
+
+
+
Infos and Indexes
-
\n\n";
-
- // Open a file
- $file = fopen("links/Infos_and_indexes.csv", "r");
-
- // Fetching data from csv file row by row
- while (($data = fgetcsv($file)) !== false) {
- // HTML tag for placing in row format
- echo "";
- foreach ($data as $i) {
- echo "" . htmlspecialchars($i)
- . " | ";
- }
- echo "
\n";
- }
-
- // Closing the file
- fclose($file);
-
- echo "\n
";
- ?>
-
-
-
+
+
+
Search Engines
-
\n\n";
-
- // Open a file
- $file = fopen("links/Search_Engines.csv", "r");
-
- // Fetching data from csv file row by row
- while (($data = fgetcsv($file)) !== false) {
-
- // HTML tag for placing in row format
- echo "";
- foreach ($data as $i) {
- echo "" . htmlspecialchars($i)
- . " | ";
- }
- echo "
\n";
- }
-
- // Closing the file
- fclose($file);
-
- echo "\n
";
- ?>
+
+
+
+