How to Build a Dynamic Credit Card Expiration Year Drop-down using PHP

Using the code below we can create a dynamic drop-down that will display the current year along with the next five years, eliminating the need to edit static credit card expiration drop-downs every year.

How to fix (and Defend Against) “$(document).ready is not a function” Issues with jQuery

If you are receiving the “$(document).ready is not a function” error (or a similar one), it’s likely another linked javascript library is causing the issue by using ‘$’ as a function or variable name. To resolve this issue, try wrapping your code in this jQuery Koozie: It’s good to get in the habit of using…

How to Make a Popup Execute Once per Session in WordPress

Start Session First, you’ll want to register your session by placing the following in your functions.php file. Create Popup Here we’ll ensure our popup only loads once per session by incrementing our ‘popup’ session variable. Include your popup markup and javascript within the following:

How to Start a Session in WordPress

You can register a session in WordPress by placing the following in your functions.php file.

How to Read RSS Feeds with PHP (using SimpleXML)

I recently rebuilt my personal website and rather than create a personal blog (let’s be honest, I barely find the time to post here!) I decided to pull a few blog and portfolio posts from our business website. To accomplish this, I wrote a couple PHP functions to parse the necessary RSS feeds using SimpleXML….

How to display WordPress Custom Posts according to Category using WP_Query

We recently did a complete overhaul of our website design and content. When redesigning our FAQ page, I decided to opt for a custom post type rather than using shortcodes. The goal was to sort the FAQ posts by category and then loop through each post for said category. This can be accomplished by the…

How to Collapse Mobile Navigation on Click in Bootstrap 3

When building a single page, scrolling Bootstrap theme, a common issue you may run into is the mobile navigation remains visible when you click on a menu item. Here is an easy jQuery fix: Check out my personal site on a mobile device to see it in action!

How to make Parent Menu Items Clickable in Bootstrap 3

By default, clicking a Bootstrap parent menu link only produces it’s dropdown menu without following that link. Adding this jQuery snippet will make your parent menu items clickable again! You can test this functionality in the navigation above!

How to make Bootstrap 3 Fixed Navbar Collapse on Scroll using jQuery

Use the following snippet to collapse Bootstrap 3’s fixed navbar when scrolling.

How to Build a Simple WordPress Custom Post Loop Using WP Query

Here we are using WP Query to pull custom posts. It is up to you to choose what you’d like to display and in what order for each post. Here we are displaying the thumbnail, title and excerpt. A huge advantage to using WP Query for your post loops is the ease of customization! Check…