User Tools

Site Tools



Hypertext Markup Language

I like to get tipsy and do HTML when it's sunny.

Cool HTML Elements

For titles of works.
For sections of stuff you can show/hide. Added a <summary> to set the title. Use <details open> to make it start unfolded.
For specifying first instance of a term. Use with <abbr> or <acronym>.
For images associated stuffs. Put a regular 'ol <img> in there and use <figcaption> for a caption.
For keyboard / button instructions.

Other Cool Things

download attribute
With <a href=“[link to file]” download> you can specify that a link is for downloading, rather than loading, by adding the download attribute.
This can also be followed by a =“[filename]” if you want it to be downloaded with a different filename that the one it has on your server.
alternate stylesheet
You can specify alternative appearances for you page, which in Firefox are accessed via View > Page Style (or Alt v y). You can also have a base sheet that is applied to all.
rel attribute
I always forget about this one. Some cool values are:
  • alternate: see above for it's use with stylesheets.
  • external for external links.
  • help.
  • next and prev for pages in a sequence, like blog posts.
  • noopener, though I think this is default in browsers now?
  • tag.

Content Security Policy

html.txt · Last modified: 2020/11/01 21:05 by rjt