frederik's blog

Music (5) Projects (2) Snippets (8) Technology (5) Thoughts (9)


Here I file useful snippets of code that I want to remember. HTML, CSS, JS, PHP, Bash, etc.

Accidentals (sharps, flats, naturals) as HTML entities

There are HTML entities for almost any symbol that we use in our daily communication – musical notation, such as sharps and flats, is available as well.

Create WordPress sitemaps on the fly without plugins

I found this snippet for creating sitemaps on an old thumbdrive and it works fine with the latest WordPress (4.9.4) – no need for yet another bloated, ad-riddled WordPress plugin!

Highlight old WordPress posts

Some WordPress posts have a very short lifespan in terms of relevance.

GNU nano syntax highlighting for screenplays

Spoiler alert: This solution for screenplay syntax highlighting sucks and I wouldn’t use it if my life depended on it.

Basic WordPress SEO without using plugins

Don’t you just hate it when you need to install a plugin to achieve one simple thing using WordPress?

GNU nano for (frugal) writers

If you’ve ever used a Linux distribution or any of the BSDs then you’re probably already familiar with the GNU nano editor.

Generate “random” passwords from the command line

I type this into my terminal when I just need a quick “random” password.

Creating WordPress menus from categories

I like to keep things simple.