Blog Category: PHP
June 24, 2020 PHP, Plugins, WordPress
After adding a new custom field to the User Insights plugin recently, I wanted to change how the date fields were displaying. Luckily, User Insights has provided a filter that we can use.
Read MoreFebruary 21, 2020 PHP, Plugins, WooCommerce
By default, the Related Posts for WP plugin displays the lists of posts after the primary content area, which is printed using a WordPress function called the_content(); on each page. …
Read MoreJuly 6, 2014 Development, PHP, WordPress
When building a website these days, include files are incredibly useful for the common pieces such as the header, footer and sidebar. In WordPress, I usually stick with the basic …
Read MoreJuly 1, 2014 Development, PHP, WordPress
A friend of mine asked recently why an old link was redirecting to a similarly named page in WordPress. Even though the page had been deleted, the link was still …
Read MoreJune 15, 2014 Development, PHP
After adding Prism code highlighter to this blog, I quickly found out that all HTML opening angles, which look like <, need to be written in their special character form, …
Read MoreMay 30, 2014 Development, PHP, WordPress
By default, the WordPress search shows results from pages and posts. One client only wanted to search their blog posts and not the rest of the pages on the site. …
Read MoreJuly 31, 2013 Development, MySQL, PHP
I wanted to use a set of database results twice on a page but didn’t want to run the database query again. Using the mysqli_data_seek() function, we can reset the …
Read MoreJuly 17, 2013 Development, HTML, PHP
While creating divs for a recent project, I wanted to assign a class to the even containers so they would float right. Container #1 would float left, #2 would float …
Read MoreJuly 17, 2013 Development, HTML, PHP
For my website, I have written a lot of news articles over the years and I wanted to print out an excerpt for each one. Instead of writing an excerpt …
Read MoreJuly 17, 2013 Development, PHP
For spam checking in an email script, I wanted to see if the name field had any numbers in it. Spammers write code that automatically fills out contact forms and …
Read More