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 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 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…

A Better Way to Load jQuery in your WordPress Theme

While WordPress comes with jQuery built in, we want to load it from Google’s CDN to speed things up. You can do this by placing the code below in your theme’s functions.php file.

How to Properly Add Scripts and Stylesheets in your WordPress theme

Simple Script and Style Enqueuing The proper way to load scripts and stylesheets in your WordPress theme is to place the wp_enqueue_scripts hook in your theme’s functions.php file. Expanding on This Sometimes you may want to load a certain script or stylesheet only on a particular page. In such a case, we can register the…