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

Removing the Link Menu Item in WordPress Admin

Remember the Links Manager in WordPress? This was an option for us to add a custom post type or “link” in the admin interface, so that we could easily link to other websites as something popularised as a Blogroll. Nowadays it’s a somewhat outdated term, and for that reason the whole Links Manager component was hidden by default in WordPress 3.5 back in late 2012.

The component is still built into WordPress though and won’t show up by default on newer installations. Older installations that have been continually updated and containing links in the database however will still show this menu item even with newer versions of WordPress. Here’s what the menu looks like:

You may also find a “New Link” item at the top of the admin page, which lets you add a new link to your database if you like:

The question is, how do we remove these options, if they still show up in newer versions of WordPress? You’d think that deleting all links and link categories would be enough, but you may have tried and already found out that it is not.

In this article I’ll show you how to do this. I’ll also explain how to bring the Links Manager back if you ever need it.

Read more