Latest Articles

Use the navigation at the bottom to see older articles

How to re-open a closed Tab in Firefox

Hey I’ve been there more times than I can count: close one or several tabs, only to think, “dang – I needed to keep that one open. What was that URL again?” Looks like I’m not alone, because many browsers support a feature that lets us re-open an accidentally closed tab. I use Firefox, and … Read more

How to style the WordPress Login Page

It’s relatively easy to add your own logo and a custom message to the default WordPress login page. Several plugins let you do that, but I’m a big fan of a little “hard coding”. It makes it easy to have all changes contained in your own files. Here are the four little helper functions I’ve … Read more

How to remove the Title and Description from Archive Pages in GeneratePress

I’ve been having great fun with the Page Hero feature in GeneratePress, and I wanted to use it for archive pages too. By default however, the Archive Title and Description show up in the Page Hero as well as underneath it. This doesn’t happen on single posts, so we’ll have a bit of work to … Read more

How to display the Category Title and Description in the Page Hero with GeneratePress

I’ve not had the best of luck adding the Category Title with the GeneratePress shortcuts in the Page Hero (the ones using the {{curly}} braces). There’s no shortcut for the description either, so I thought I’d write my own and show you how I did it. First I’ve created two regular WordPress shortcuts for the … Read more

Where is the WordPress is_blog() Function

At first glance, there appears to be no conditional function to test if we’re on the user’s blog page. Which is weird, since can test so many other things with WordPress Conditionals: is_singular(), is_page() or is_front_page() and is_home(). Sadly we cannot test if the current page is in fact displaying the blog with something like … Read more

How to embed your latest YouTube Video with responsive CSS

I’ve recently had to update the code that’s responsible for pulling in my latest YouTube upload on the front page. I had previously used a solution that uses the channel name rather than the channel ID. Apparently that API has stopped working and I had to find a workaround.

In addition to making it work again, I also wanted my embed to be responsive and look handsome on all screen sizes. The trouble is that regular iFrame embeds use a static size for the video (like 600×360 or 800×480), but being the future-proof thinking kind of guy that I am, I wondered if there was a way to make this dynamic. The “height=auto” trick didn’t work for me, but thankfully I came across a great piece of CSS that adds this feature.

Let me show you both parts to solving this puzzle.

Read more