A really janky webring made with Go and JavaScript for South London.
Go to file
Jake 05309bd80c
Add binary to gitignore
2021-04-08 17:45:49 +01:00
templates Prevent random choosing the same person 2021-04-08 17:42:41 +01:00
.editorconfig Initial code 2021-04-07 22:29:12 +01:00
.gitignore Add binary to gitignore 2021-04-08 17:45:49 +01:00
README.md Update readme 2021-04-08 10:38:43 +01:00
go.mod Update name 2021-04-08 10:30:04 +01:00
go.sum Initial code 2021-04-07 22:29:12 +01:00
main.go Add abosolute paths 2021-04-08 10:34:06 +01:00
users.go Add abosolute paths 2021-04-08 10:34:06 +01:00

README.md

South London Webring

This is a work in progress!

Every tilde seems to have a webring, so this is one I made for South London.

This is quite janky as there's no PHP, so the redirection is done using JavaScript on pages that are injected with a user list through Go. When someone joins the ring through the Go script, these pages are updated along with a users.json file.

Install

git clone https://tildegit.org/jakew/webring.git
cd webring
go build -o manage .

Give the binary a suid bit so that when people execute the program the program can update the pages without the user having permission.

chmod u+s ./manage

Usage

The webring can be joined by running the binary.

./manage

The pages in the output folder are then updated to reflect the new person in the webring.

Each user needs to have a snippet like so on their webpage.

<a href="https://southlondon.cc/~jakew/ring/prev.html?USERNAME">previous</a>
<a href="https://southlondon.cc/~jakew/ring/random.html?USERNAME">random</a>
<a href="https://southlondon.cc/~jakew/ring/next.html?USERNAME">next</a>
<a href="https://southlondon.cc/~jakew/ring">how to join this webring</a>