diff --git a/ring/index.php b/ring/index.php index 9317bab..d8d3f0a 100644 --- a/ring/index.php +++ b/ring/index.php @@ -23,7 +23,14 @@ if ($action !== "index") { die("invalid action"); } - header("Location: https://tilde.team/~$user/"); + // use custom link from second line of ~/.ring + if (filesize("/home/$user/.ring") > 0) { + $ringfile = file("/home/$user/.ring", FILE_IGNORE_NEW_LINES | FILE_SKIP_EMPTY_LINES); + if (count($ringfile) > 1 && $ringfile[1] !== "") + $dest = trim($ringfile[1]); + } + $location = $dest ?? "/~$user/"; + header("Location: $location"); die(); } else { @@ -54,18 +61,26 @@ else {

then create a .ring file in your ~ to be added in the webring:

$ touch ~/.ring
-

the first line of ~/.ring will be displayed here as a tagline

+

the first line of ~/.ring will be displayed here as a tagline.

+

the second line of the file is used as a custom link if your webring tags are not on your homepage.

explore webring

jump to random page

all members: