Earth Notes: On Website Technicals (2021-02)Updated 2022-10-23 12:06 GMT.
By Damon Hart-Davis.
2021-02-28: DNS Secondary Fun
I have been a bad boy, and not kept a DNS secondary running for a while, since my US host simply went off the air and apparently out of business too.
(For good response to a large chunk of the world's search engines, etc, I want my secondary to be somewhere well-connected in North America.)
As of today I finally have the replacement Canadian server running, with the editing of my master DNS records, glue records at various registries, and some manual and Ansible remote configuration of the Canadian server.
I aim to move some other replica servers to that host in due course.
2021-02-06: Dark Mode Image Tweaks
As a super-fast super-simple super-low-bandwidth preview / progressive view for images, I generally set the
attributes and also something like
and some form of lazy or async load and render.
This renders the whole area of the image in a single representative colour. Currently this is the image 'average' mapped to a nearby
from the Netscape 'safe' 216 colour cube.
I don't do this for images with transparency, as I want the background to show through.
Until now I haven't done this either when the representative colour was the (white
#fff) background colour, since it would likely consume a few bytes to achieve no visual effect.
As of today I also decline to use this
background when it would be black (
#000), since that would have no visual effect for dark mode. It turns out that that only affected at most about eight images!
Just before this change I did a census of all the existing cached image background values (including
#000), by count and colour:
So, 47 out of the possible 215 (
#fff having been excluded), 1623 images total. This may include several size/shape variants of each source. For example, those that did have a black 'average' colour cached were:
img/a/b/dded2a9b8bddb768e012ba8040f4536d.l178481.576x473.m.png img/a/b/dded2a9b8bddb768e012ba8040f4536d.l178481.720x591.png img/a/b/low-8200111b64762a96c5f79ca0074baa71.l3097053.211x158.m.jpg img/a/b/low-8200111b64762a96c5f79ca0074baa71.l3097053.264x198.jpg img/a/b/low-8200111b64762a96c5f79ca0074baa71.l3097053.43x32.jpg img/a/b/low-8200111b64762a96c5f79ca0074baa71.l3097053.43x32.m.jpg img/a/b/low-energy-LED-fairy-light-9m-50-lamp-string-cool-white-solar-PV-powered-Maplin-N34HN-5-DHD.l3097053.43x32.jpg img/a/h/G-DRIVE-2TB-landscape-letterbox-800w.l9005.248x177.jpg
The most common colours seem to be various shades of grey, plausible given the automatic white balance of most pictures when taken.