This Contact Form 7 Boilerplate will help you to reduce the time to configure a Contact Form 7 WordPress plugin. You can use this Boilerplate to setup contact form 7 for a generic form to collect Name, Phone, Email and Message from a users. This will work on most small business website. Please note that this […]
Display Related Post or Product based on Taxonomy in WordPress
Related post display in for custom post type is very easy. But if you have a custom taxonomy it is little tricky. You can use the following code to display related post from a post type. This code very useful to display related product while you are using custom taxonomy. <?php // get the custom […]
How to Reduce the Character Length of WordPress Post Title
WordPress by default display fill title if you code it using via the_title() function. You can reduced the number of character display by using following simple code. <h1><a href=”<?php echo get_permalink() ?>”> <?php $title_temp=the_title(”,”,false); if(strlen($title_temp) > 30) { $title_temp = substr($title_temp, 0, 30) . ‘…’; } echo $title_temp; ?></a></h1> For example if you have space […]
How to get Facebook likes count of a page using Graph API 2.8 Ver
(11/2016 Updated): This is an updated and working code snippet which can be used to retrieve Facebook like count of a specific page. To use this code snippet you’ll need a Facebook App ID and Secret Key. This use latest 2.8 API version method.
How to Display Post from a Particular Category in WordPress
WordPress category specific loop. You can use this simple wordpress to look take post from a category. This is best method for display post from a Particular category. <?php query_posts(‘cat=11&showposts=5’); ?> <?php while (have_posts()) : the_post(); ?> <a href=”<?php echo get_permalink() ?>”> <?php the_title(); ?></a> <?php the_content(); ?> <?php endwhile; ?> <?php wp_reset_query();?>
- 1
- 2
- 3
- …
- 5
- Next Page »