Skip to content
Article

WordPress Plugin – Featured Heroes Slideshow

Here’s a WordPress plugin that will allow you to create a slideshow from posts – using either the provided “Heroes” content type or any other post type.  Added bonus – you can place the slideshow anywhere with a shortcode.

Download ABT Featured Heroes  Download from WordPress

As taken from the readme file:


Description

Provides a new content type “Heroes” to manage your featured slides. You can then add a slideshow to any page using the shortcode abt_slider_hero. The slideshow is automatically configured using jQuery Cycle and the options you specify in the shortcode.

One of the options postType allows you to use other content than the provided “Heroes”, effectively allowing a slideshow of almost anything in WordPress.


Installation

  1. Unzip, upload plugin folder to your plugins directory (/content/plugins/)
  2. Activate plugin
  3. Add slideshow shortcode anywhere you need it.
  4. If you want to put the widget (shortcode) in a Widget, you’ll need to allow shortcodes in widgets
  5. You can call the slideshow in code using abt_featured_heroes::embed( array $atts )

Frequently Asked Questions

What is the shortcode?

Use the following format (defaults indicated here):

[abt_slider_hero fx="fade" width="100%" height="400px" order="asc" orderby="menu_order" speed="600" timeout="7000" classes="" postType="heroes" style="photo"] 

where

  • fx = the cycle transition effect (fade, scrollUp, shuffle, etc) – see jQuery Cycle homepage for more information
  • width = width of the slide
  • height = height of the slide
  • order = sorting order (asc/desc) for the fetched items
  • orderby = how to sort the fetched items
  • speed = transition speed from one slide to the next
  • timeout = delay between slide changes
  • classes = optional classes to apply to the slideshow
  • postType = you can retrieve other content types than “heroes” if desired
  • style = normally the thumbnail navigation just reuses the full-size image, but if you want to “control” the quality of the shrunken thumb specify an alternate image size (like “thumbnail”)

Pretty much all of the attributes are optional, so all you need is:

[abt_slider_hero] 

How do I put a slideshow in code?

You can call the slideshow in code using abt_featured_heroes::embed( array $atts ), where $atts is an array matching the shortcode attribute list.

Can I change the defaults?

Only one simple hook available:

  • add_filter('abt_featured_heroes_localize', YOURFN);change the base javascript variables used by the flipwall init script:
    • stylesheet: replace the default stylesheet with your own to change the default appearance of slides
    • speed: change the transition speed (from 600 ms)
    • timeout: change the slide delay (from 7000 ms)
    • fx: change the slide transition (from ‘fade’)
    • style: optionally use actual thumbnail photos for navigation, instead of reusing full-size images (default ‘photo’, alt ‘thumbnail’)
    • width: default width (from 100%)
    • height: default height (from 400px)

How to put shortcode in widget?

Use a filter to apply shortcode processing to widgets.

Filter: <?php add_filter('widget_text', 'do_shortcode'); ?>


The Atlantic BT Manifesto

The Ultimate Guide To Planning A Complex Web Project