SD card image to webpage issue

Steve2018:
Anyway, I clearly don't understand that bit, so I will have to rethink my method.

Instead of “rethinking” a new incorrect way to do it, why not try the method from the (presumably) working example that you incorrectly emulated?