Test phase
The publishing API is being tested. An 8TML editor (SEE64YOU on the C64 Ultimate) and a reference server are trying it out to find what works and what doesn’t, so it may still change, also in ways that break older programs. When it has settled, a publishing package will be released so that anyone can publish 8TML on their own site. Until then, build on it only for testing.
Publishing means getting your files onto a web server. 8TML pages and stylesheets are plain files, so there are several ways to do it.
Copy the files yourself
On your own web server, copy the files with whatever you already use: FTP, SFTP, rsync or your host’s control panel. Then check the server settings in Hosting 8TML pages. That’s all a static 8TML site needs.
On T8wn
Plots on T8wn are written in the editor on the website, which also uploads files (one at a time, or a whole plot as a ZIP file), or published from other editors through the publishing API: make a key file on your Account page and give it to your editor or tool. Every way of publishing gives a page whose header names no stylesheet a style: line for the plot’s own stylesheet, plot.8ss, and says so in a warning.
From an editor, with the publishing API
Editors and tools publish through the publishing API, an HTTP interface simple enough for an 8-bit computer. It works like this:
- Your hosting service gives you a key file on its website, over HTTPS. Make one key for each machine or tool.
- Copy the key file to the machine’s storage, for example its SD card or a disk image. Never send it over plain HTTP.
- The editor publishes your pages with that key.
The editor talks to the server in one of two ways:
- Signed, over plain HTTP: the machine signs every request with the key, and the key itself never travels. Your pages travel readable, which is fine for public pages. Signing costs time on an 8-bit machine: about 1.3 seconds per kilobyte on a 1 MHz 6502, mostly while the page is being sent anyway.
- Over HTTPS, through a proxy: the machine sends its request with the key to an HTTPS proxy on your own computer, which passes it on over HTTPS. The machine needs no signing code, but the key crosses your home network unencrypted, so use this only on a network you trust.
If you lose a machine or a disk with a key on it, revoke that key at your hosting service and make a new one.
Your own server with an editor
To publish from an editor to your own server, the server needs a program that answers the publishing API (an endpoint). The reference endpoint is a PHP script that runs on ordinary web hosting; it is being tested on T8wn and will be part of the publishing package.
The exact rules are in the Publishing API reference.