Contextual Related Posts 2.0

Contextual Related Posts

Last week I released a major update to Contextual Related Posts. Given the size of the update, I’ve tagged the latest version as 2.0, heralding a new direction in the further development of this plugin.

v2.x brings multi-site support, WordPress thumbnails and a more powerful API. It also has several minor bug fixes and cleaner code.

Multi-site support

One feature that has been missing from Contextual Related Posts has been multisite support, mainly in terms of a Network Activate feature. With the Network Activate feature enabled, a multi-site admin can choose if he wants to activate Contextual Related Posts across all sites in the network or let users activate the plugin independently on their site.

CRP - Network Activate

Network Activate Contextual Related Posts

Once you network activate the plugin, it will no longer show up in the Plugins page of the individual sites. However, users can visit Settings » Related Posts as usual to configure the plugin. If you don’t Network Activate the plugin, it will show up on individual sites and the site admin can choose to activate the plugin if he/she so chooses.

WordPress thumbnails

CRP has had support for timthumb for a long time and by default timthumb was used to create thumbnails. Although timthumb gives you much better control on thumbnail resizing, it does add slightly higher processing on the servers since the images are created on the fly.

Many users have requested to include support for WordPress’ inbuilt image resizing and this feature has found it’s way in v2.0 of Contextual Related Posts.

Thumbnail options in Contextual Related Posts 2.0

Thumbnail options in Contextual Related Posts 2.0

Contextual Related Posts will add a new image size called crp_thumbnail based on the settings above. This means WordPress will create a copy of the image with the specified dimensions when a new image is uploaded. By default, this is set to proportionally crop the image. i.e. the image will first be resized so that the max dimension is as per the above i.e. 150px. You can optionally choose to hard crop the image by enabling the crop mode above. This will cause the image to be cropped to the exact dimensions but this might result in some part of the image being chopped off.

In either case, I strongly suggest running a regenerate plugin like Force Regenerate Thumbnails to recreate the image sizes for your older images. I especially like this plugin because it deletes the old and unneeded image sizes that would have been created in the past and are unnecessarily occupying space on your server.

Extended API

In version 2.0.0, I’ve added several new filters and actions that will allow other plugins / themes or addons to talk to Contextual Related Posts. What’s currently missing is the documentation which I shall be working on over the next several weeks.

If you’re interested in the API, take a look at my new plugin Contextual Related Ports Taxonomy Tools. Available for free from WordPress.org, CRP Taxonomy Tools adds support for restricting posts to the same categories and tags of the current post.

CRP Taxonomy Tools

CRP Taxonomy Tools

This is also a working example of the API that adds settings to Contextual Related Posts and also filters the post query.

Contextual Related Posts on Transifex.

Contextual Related Posts is now on Transifex, ready for translation courtesy the WP Translations. WP-Translations is the place where you will find a number of WordPress amazing Plugins and Themes to make them available in your home language. In exchange you will receive credit for your work and will certainly make part of the WP community history in your country.

If you’re a translator, do consider joining the Wp Translations team. Visit Contextual Related Posts on Transifex.

Closing words

As usual, if you’ve got any questions please open a support ticket in the WordPress.org forums. It allows me to answer your question quickly and more efficiently. Emailing me your support query or writing it in a comment is most likely going to be missed due to volume of emails I receive.

If you’re an existing user of the plugin, do consider writing a review. WordPress developers are welcome to contribute to the plugin via GitHub. Create an issue or fork the plugin and submit a pull request for me to review.

And, before I forget, Contextual Related Posts also has a brand new header.

Contextual Related Posts

Detailed changes in 2.x

2.0.1

  • Fixed: Clear Cache button which broke in 2.0.0

2.0.0

  • New: Multi-site support. Now you can Network Activate the plugin and all users will see related posts!
  • New: Thumbnails are registered as an image size in WordPress. This means WordPress will create a copy of the image with the specified dimensions when a new image is uploaded. For your existing images, I recommend using Force Regenerate Thumbnails
  • New: Completely filterable mySQL query to fetch the posts. You can write your own functions to filter the fields, orderby, groupby, join and limits clauses
  • Modified: Lookup priority for thumbnails. The thumbnail URL set in the Contextual Related Posts meta box is given first priority
  • Modified: Removed border=0 attribute from img tag for HTML5 validation support
  • Modified: Default option for timthumb is disabled
  • Modified: Default option for post types to include is post and page
  • Modified: get_crp_posts has been deprecated. See get_crp_posts_id instead
  • Modified: Turning on the Default style will switch on thumbnails, correctly resize them and will also hide authors, excerpts and the post date
  • Fixed: Post image will now be loaded over https if the visitor visits your site on https

Download Contextual Related Posts

Contextual Related Posts Taxonomy Tools

Contextual Related Posts allows you to display highly relevant posts on your WordPress blog.

CRP Taxonomy Tools gives you the option to restrict these related posts to the same category and/or tag of the current post. The plugin will add two checkboxes under General options under the Related Posts page.

Requires Contextual Related Posts v2.0 or higher.

- Download it from Github
Download it from WordPress.org

Add to Feed and Add to Footer v1.3

Add to Feed General Options

I released v1.3 of Add to Feed and Add to Footer plugins for WordPress. Existing users should be able to upgrade directly from within their Dashboards.

Add to Feed General Options

Add to Feed General Options

Add to Feed is a feed enhancement plugin that allows you to easily add a copyright notice and custom text/HTML to your WordPress blog feed. The custom text can be entered before and/or after the content of your blog post.

Add to Footer allows you to add any HTML or JS code to the footer for your WordPress theme. This ensures that you don’t need to keep adding the same code in case you change your theme. Simply enter the settings once and you’re good to go!

These are both light weight versions of my plugin Add to All which combines the features of both above but is still pending a code refresh.

Changes in Add to Feed v1.3

  • New: Completely redesigned admin interface
  • New: Option to disable the admin-wide notice when the plugin is disabled
  • New: Customise the title text that will be displayed.
  • Fixed: Integration with feed will also work well with excerpts
  • Fixed: PHP notices when WP_DEBUG is set to true

Changes in Add to Footer v1.3

  • New: Support for Google Analytics’ new Universal Analytics
  • New: Admin interface
  • New: Disable admin notice if the plugin is disabled
  • Fixed: Language initialisation and renamed localisation to add-to-footer

Better Search v1.3.3

Better Search - Seamless integration

I pushed out v1.3.3 of Better Search. The plugin replaces your WordPress search results with highly relevant search results.

This version comes with a brand new responsive admin interface similar to my other plugins as well an option to disable tracking of admins and editors. My favourite new addition to the plugin is the seamless integration mode. This mode no longer needs any search templates and gives you results completely integrated within your WordPress theme. This makes it completely compatible with all WordPress themes. This will soon be the new default option for fresh installs.

Better Search - Seamless integration

Seamless integration will give you relevant search results just like how your theme delivers it!

If you use get_bsearch_heatmap manually in your themes, please be aware of the new syntax. The function now accepts a big set of parameters in an array format. All these are optional and if you choose to not pass one of these then it will default to the option set in the Settings page.

As usual, if you’ve got any questions, please make a post in the Support Forum. And if you’re using the plugin, please do leave a good review.

All changes in v1.3.3

  • New: Responsive admin interface
  • New: Seamless integration mode. With this enabled, you can benefit from relevant search results displayed how your theme intended it to be!
  • Modified: Modified get_bsearch_heatmap to accept an array of parameters. If you’re using this function, please note the modified usage in the FAQ
  • New: Option to turn off tracking searches of Admins and Editors
  • Fixed: Widget initialisation
  • Modified: Reformatted code to follow WordPress PHP Standards

Download Better Search v1.3.3

Top 10 v1.9.10.x

Top 10 Meta box

I pushed an update for Top 10 a few days ago which brings you some cool new features including the ability to edit counts, set thumbnails and improved shortcode options.

Following along the lines of Contextual Related Posts, Top 10 v1.9.10 brings a new meta box on your Edit Post / Page or Custom post type screen that allows you to set the custom thumbnail as well as edit the post count for the post.

Top 10 Meta box

Meta box on Edit screens will allow you to set the thumbnail and edit the post count

The meta box will use the same meta field as specified in the General Settings. If you’re using the default field name i.e. post-image and you’re using my other plugins Contextual Related Posts and Where did they go from here, then they will automatically recognise this thumbnail!

Another major change in the plugin is the use of the shortcode. You’re no longer restricted to three parameters as earlier, but all the options that can be passed to tptn_pop_posts(), which is all the settings that you can configure in the Settings page. Check out the function tptn_default_options if you’re curious for what is configurable.

The latest version of the plugin also brings the ability to turn off tracking for Editors. This is especially useful if you have a multi-user blog and Editors routinely edit posts and visit these posts.

As usual you can upgrade the plugin from within your WordPress admin. If you’re using Top 10, do consider giving it a 5-star review! If you got questions, please use the forum.

Emails and comments are not the best way to get support unless you’re willing to hire me to solve your problem related to Top 10!

Changes in v1.9.10.1

  • Fixed: Initialisation error for new installs

Changes in v1.9.10

  • New: Meta box on Edit post / page and similar screens that allow you to set the Top 10 (and my other plugins) specific thumbnail for the current post (different from the Featured thumb)
  • New: Admins can edit the number of total views (find it in the same meta box as above)
  • New: Turn of tracking for Editors
  • New: Added w.org and github.com to list of allowed sites for timthumb
  • New: Option to add quality settings for thumbnails created by timthumb
  • Modified: Shortcode now accepts all the parameters that tptn_pop_posts() can take. For a full list of parameters, please check out the FAQ.
  • Modified: Widget initialisation to latest standards
  • Fixed: Localisation initialisation
  • Fixed: Validation for hour and minute settings for the cron job
  • New: Several new filters allowing you to hook in an modify the output without editting plugin files
  • Modified: Reformatted code

Download Top 10 v1.9.10.1