Cronblocks for WordPress

Share This Post

A couple of years ago I had an idea of a project targeting people who want to offer dynamic content on their sites but do not have the programming knowledge to do so. I called it Cronblocks (http://cronblocks.com) – a system where the user can create snippets of content and choose when to display them. Not satisfied, I decided to add Geo-Location as a possible condition for displaying the snippets. It worked (and still works) fine for sites built in plain html or any programming language as the code is sourced via Javascript.

I recently decided to write a port of Cronblocks as a WordPress plugin as a proof of concept, with the following features:

  1. Snippets are a WordPress Custom Post Type
  2. They can (and should) be grouped into category-like taxonomies called Snippet Groups
  3. Set the snippet controls to use either Geo-Location (visitor’s country) or a Scheduled display time range and date (choose days of the week or days of months)
  4. Assign the Snippets to a Snippet Group (just like categories)
  5. Control overlapping Snippets in a Group with Priorities

To use it, place the Snippet Group shortcode to control where on your page/post you want the appropriate Snippet to be displayed, and that’s it!

The plugin will check for all snippets associated with the shortcode’s Snippet Group and will decide which one should be displayed according to the control settings for each Snippet. If more than one Snippet match the display conditions, a random one of the matching set will be selected.

As mentioned above, this is a proof of concept. I plan on writing a fully featured companion plugin that will offer the following:

  • Enable multiple control conditions of each type, and mix/match
  • Keep and show statistics of snippets being displayed
  • Optionally display snippets based on the visitor’s local time
  • Optionally reload the snippet group after a given amount of time (say a visitor is watching a video, reload the snippet group after 3 minutes)
  • Enable Region and City scope
  • Use Maxmind GeoIP2 database, which is more accurate than the GeoIP databased used in the Cronblocks plugin
  • Allow overriding of snippet options via the shortcode attributes
  • Set up roles that can access the snippet administration
  • Add an icon to the TinyMCE interface as a shortcut to inserting the shortcode
  • Add a Snippet Group Widget

While the fully featured one doesn’t come out, feel free to download the proof of concept from WordPress.org’s plugin repository: Download

 

More To Explore

Documentation
vinny

bbPress Notify (No-Spam) Documentation

bbPress Notify (No-Spam) Documentation The bbPress Notify (No-Spam) is a free plugin that lets you control who gets notifications of new Topics and Replies in

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.