Code
It is Possible to Include HTML Fields in Notifications and Confirmations I recently needed to create conditional logic in a Gravity Form that shows HTML fields in response to various user inputs. The trouble is that HTML fields do not appear in the default Notifications and Confirmations. Gravity forms support says the HTML fields are … Read more
I had a pretty serious problem with s2Member EOT reminders not being sent on a website with a large user base, about 2000. This was resulting in potentially a large loss of member renewals. The strange thing was that many of the EOT reminders were going out, so it made me lax in checking if … Read more
On a recent project I needed to check if a Gravity Form had been submitted before allowing the user to access content. Additionally we needed to check if the submission had happened within a specific time frame: within the past year. It is easy to use Gravity Forms built in confirmations to redirect to a … Read more
I needed to exclude specific custom taxonomy terms from the Genesis [post_info] shortcode which by default lists all the terms in the taxonomy in the post meta. I achieved this by modifying the get_the_terms_list() function, which is used in the Genesis post_info shortcode. Then create a new shortcode [filtered_post_info] to use instead of [post_info]. The … Read more
Here’s the problem: You have a custom taxonomy and you need to create a taxonomy dropdown list, similar to the WordPress category dropdown option. You need to have multiple taxonomy dropdowns for the child terms within the taxonomy. (get_term_children) These term lists should be sorted alphabetically. When selected the term should link to its archive … Read more
Gravity forms has a nice option in the settings area to remove it’s css output from all pages. However when you want to remove the style-sheets from individual pages it gets more complicated. Here’s a simple function which will remove Gravity Forms CSS and selected scripts from the front_page: Cut and paste this code into your … Read more
WP_User_Query doesn’t give direct access to the user avatar, so how to show the avatar? Regular profile fields are easy to reference from the codex. But what about custom meta fields? Displaying the avatar and other user meta with WP_User_Query isn’t quite straight forward. Some user profile data is returned by default, but user meta … Read more
Since there are already so many great articles out there about the usefulness of adding Schema.org Microdata to your HTML5 markup, I’ll let Google help you out on that. I encountered a situation where I needed to change all microdata for single blog posts, archive pages, home page and any other place a blog post … Read more
There are many reasons one might want to export the WordPress users and import them to another install. In my case, I needed to recreate a hacked website. I wanted to take all the content and migrate it without doing a full database restore for a database which might contain who-knows-what kind of evil hacker … Read more
When I set out to change the settings for the default WordPress activation email subject, message and sender, I thought it would be a pretty obvious thing to change. I was wrong. Here’s what happens and how to customize it: When a new user signs up a new WordPress account, they need to activate it … Read more