When creating new posts for a video demonstration, I wanted to display a consistent date. While my first thought was to reset my system clock, this snippet overrides the date when the post is first created, which worked for me.
I like to use the Scriptless Social Sharing WordPress plugin to add Share buttons to my blog posts. Recently I had a client notice that because the Email Share button has target=”_blank” in the HTML markup, it opens a new tab when clicked. This is great behavior if you’re using web based email (e.g. Gmail), however if you’re using an email application on your computer, you end up with a blank tab. This code removes target blank from the email share link.
I often find it helpful to add a label to the Featured Image area in the WordPress admin. By guiding clients to upload the appropriate sized image, it lets me avoid them being surprised by WordPress cropping their image in an unexpected way.
When it comes to adding social sharing buttons (e.g. “Share on Facebook”), I’m a big fan of Scriptless Social Sharing by Robin Cornett. The one thing I like to do when using it is add UTM parameters to the links that are shared. Here is the snippet I use to add UTM parameters to my URLs that are being shared.
As a WordPress developer it is a painful (and all too familiar) feeling of angst, when I find a plugin that does almost exactly what I want but the author has left no way for me to modify the behavior without changing their code. Don’t Hack Core (or plugins) A popular refrain in WordPress developer […]
Recently, I wanted to add content to each item in the RSS feed on a WordPress site. This could be something like: Hire Sal If you enjoyed this article, have you considered hiring Sal to help with your project? To add this, we can leverage the WordPress filter the_content_feed. The code would look something like […]
I find I spend very little time on the WordPress dashboard. Additionally, the Dashboard can be confusing for users when all you want to do is write a blog post. Thanks to the power of WordPress filters, we can send users directly to the backend Posts screen on log in and skip the dashboard. We […]
I am a huge fan of the WordPress plugin Yoast SEO, however I’m not a big fan of the notifications it includes. Leveraging the power of WordPress filters, we can suppress these messages. The following information is based on Yoast SEO 3.2.3 and may not be accurate for other versions. The Notifications to Eliminate There […]
I found this a really interesting problem recently. I wanted to migrate users from Magento to WordPress without forcing them to reset their password. You can’t export passwords for Magento or any well engineered web application, so the interesting part is migrating these passwords without ever knowing what the passwords are. Quick Background for those […]