What's been on my mind

Cape Town 1.6°C above normal in 2018

Submitted by charles on Thu, 02/07/2019 - 10:30

The New York Times has a tool on their site which allows you to check how much warmer a city was in 2018, compared to an average calculated using data from 1981 to 2010. The data, provided by AccuWeather, comes from a database of more than 3800 cities worldwide which shows that about 83% of cities experienced average temperatures higher than normal last year.

Copying multiple words in PhpStorm

Submitted by charles on Wed, 01/23/2019 - 12:43

To copy multiple, non-adjacent words in PhpStorm, option click at the start of each word, then hold option and shift and hit the right-arrow key and each word will become highlighted. Ctrl + c to copy and then move to where you want to place the copied words and paste (Ctrl + v). You can also add extra text before or after the copied words, and the extra text will occur in the same place on each line from which the words were copied.

"Plastic Nightmare": a presentation in Kommetjie by Surfer and Scientist Dr. Tony Butt

Submitted by charles on Mon, 08/20/2018 - 15:00

Surfer and oceanographer Dr. Tony Butt, who has been a regular at the big wave spots around the Kommetjie area over the years and who has given talks about the science of waves and geomorphology, spoke again this evening at the Kommetjie Surf Shop, but this time it wasn’t about surfing or the formation of waves, rather he presented his research and thoughts on this “Plastic Nightmare” we are living in and are all contributors to.

Prompting a user to confirm navigation away from a page using the "beforeunload" event in javascript

Submitted by charles on Sun, 08/19/2018 - 13:43

To brush up on, and solidify my javascript knowledge, I'm currently going through the book "Eloquent Javascript", and came across the brief mention of "load" and "unload" events. I'm well aware of and use the "load" event all the time, but I haven't actually needed to use the "unload" event in any custom js code of mine before, so while the book doesn't really go into any detail I looked at the MDN's "beforeunload" documentation for some more info.