How to Get Better Post Sorting Order Using a Weighted Formula

gray and brown mountain

Whether you’re sorting posts in your WordPress blog, products on your WooCommerce store, or topics and replies on your bbPress forum, having a system of intelligent sorting is critical to highlighting the most popular and useful content for your users.

In this post, I’m going to dive into the problems with standard sorting methods, show you the “holy grail” of sorting methods, and even share with you how you can start utilizing this weighted score sorting on your website today.

Continue reading How to Get Better Post Sorting Order Using a Weighted Formula

How to Add Voting to bbPress Topics and Replies

bbPress Voting

If you have a WordPress site with a bbPress Forum and you’re looking to add user voting functionality, then you’ve come to the right place.

As an experienced WordPress developer and the developer of the free bbPress Voting plugin, I have extensive experience with this that I’m happy to share with you.

Continue reading How to Add Voting to bbPress Topics and Replies

Function for a Dynamic Title for WordPress Blogs

shahadat-shemul-O2MdroNurVw-unsplash

Are you a WordPress theme developer and you’re running into some frustration with getting the <h1> Title of a page to show properly on archives, categories, search results, and single posts?

Continue reading Function for a Dynamic Title for WordPress Blogs

How to get Hover Dropdowns in Bootstrap 5 Navbars

Class Object Oriented PHP

With the release of Bootstrap 5, the developers had made a decision to not support hover dropdown. They claim it has something to do with user experience on touch devices… whatever. I don’t buy it. On phones and small tablets, you’ve got the mobile menu, so you’re good.

Continue reading How to get Hover Dropdowns in Bootstrap 5 Navbars

Fix VS Code Update Error: There was an error while Deleting a directory

shahadat-shemul-O2MdroNurVw-unsplash

If you found this page, then most likely you’re updating or restarting Visual Studio Code (referred to as VS Code) and you got this error message…

Continue reading Fix VS Code Update Error: There was an error while Deleting a directory

CSS to Force Element Full-Width When Inside a Max-Width Container

container element with full width element inside

If an element like a image is wrapped by a container that has a limited width, how do you make the inner element expand outside the bounds of its container to stretch full-width of the browser window?

I used to think it could only be done with Javascript.  The reason is because there was a WordPress page builder that I used years ago that had a stretch full-width feature which used Javascript to accomplish it.

Well, thanks to the power of modern CSS, we can use calc() and vw solve this problem wonderfully!  Here’s how to do it. Continue reading CSS to Force Element Full-Width When Inside a Max-Width Container

How to Add Wide and Full Align Buttons to Block Lab

Block Lab Wide Full Align

Are you using the Block Lab WordPress plugin, but need the Wide and Full align buttons on your custom Gutenberg blocks?  These code snippets will add this missing feature.

Continue reading How to Add Wide and Full Align Buttons to Block Lab

How to Change VS Code’s Integrated Terminal to Git Bash

VS Code

When you first started using VS Code you may have dismissed that little notification in the corner that asked if you wanted to switch your integrated terminal.

In my case, running on Windows, the default terminal was set to Command Prompt (cmd.exe) which is just plain inferior to Git Bash which you probably already have installed if you have installed Git (which you should).

So, if you missed that notification that let you change it, how do you change it later?

Continue reading How to Change VS Code’s Integrated Terminal to Git Bash

Best Practices for Safe WordPress Updates on Big Revenue-Critical Websites

WordPress Updates

In my WordPress developer career, I’ve been asked many times about the best practices for safely updating WordPress core, plugins, and themes, especially when it comes to a site that can’t afford to have any downtime.

There are several update strategies to consider.  I’ll go over them here.  It’s really all up to the client’s risk tolerance vs. their willingness to pay for extra maintenance work.

But, with my WordPress update strategies, you should be able to perform updates the safe way without too much extra effort.

Continue reading Best Practices for Safe WordPress Updates on Big Revenue-Critical Websites

How to Remove Unrelated Videos From All WP Gutenberg Video Embed Blocks

Remove YouTube Related Videos WP Block

Looking to get rid of the annoying and horribly unprofessional “related videos” end screen on your professional YouTube video embeds on your WordPress website?

I’ve put together the perfect simple solution in the form of a small code snippet that you can drop into your theme’s functions.php file.

Continue reading How to Remove Unrelated Videos From All WP Gutenberg Video Embed Blocks