This plugin produces a jQuery powered slider.
The current version is 1.3.
The slider can be used in three ways.
PHP code can be "hard-wired" into any template, thus:
A shortcode can be added to any page or post, to add the slider.
The slider can be added in a widget. The plugin installs the OCWS Slider Widget into the Widgets panel. The widget creates a much reduced slider.
Only one of the above implementations can be used.
The plugin has three types of slide properties - basically three sizes of images. The base sizes are actually expanded or contracted, because the slider is fully responsive to the media size in which it is displayed. The three sizes are:
- Default (ocwssl_function). Width: 600; Height: 280.
- Widget (ocwssl_widget). Width: 150; Height: 83.
- Ultrathin (ocwssl_thin). Width: 600; Height: 75.
Note that the ultrathin version uses a different ratio of images. If using this size, it might be best to prepare the images in advance. If you do so, I recommend making the images 1200 x 150, and allowing the plugin to adjust the sizes responsively.
Creating the Slides
This slideshow can display up to 5 slides. It does this, by implementing a new custom post type, called Slider Image. This can be seen on the left of the Admin Menu. Each Slider Image 'page' has only two parameters for you to worry about - the Title and the Featured Image (which is the image that will be displayed.
The Slider admin page has just these four features to adjust, before publishing.
The first job is to set the slide title. You should also have a brief comment (Main Info Line), to describe the slider, though this is optional. You can also add a Link URL. If you add a Link URL, then the system will add the words "Read more..." to the info line, and turn this into a link, that leads to the relevant page. These first three elements are deployed as shown below.
The fourth, but obviously the most important element, is to set the Featured Image, because this is the element that actually constitutes the picture for the slider. For this special custom post type ("Slider Image"), the featured image box has been moved, and the image made full size.
The list of Slider Images can also be seen here:
As is common these days, with major Open Source projects, this plugin builds on a great legacy.
- The structure of the plugin coding follows closely that of the Nivo Slider tutorial at TutsPlus http://code.tutsplus.com/tutorials/build-a-slideshow-plugin-for-wordpress--wp-25789
- Several other features have been cannibalized from my OCWS Creation Cache plugin.
Three features occur to me.
- An options panel to determine the sizing of the Slider Images.
- A method for implementing multiple sliders.
- Micro-thumbnails of the Slider Images posted in the Admin Slider Image list.
- A routine for choosing the order of slide display.
New Poster Size (1600 x 700) for front page display produced.
Default capabilities temporarily disabled, due to a fault.
Added default capabilities
Capabilities have been added, in order to restrict certain user roles.
If the slide order is set to zero, this slide will not appear in the slideshow. Consequently, there is complete control over the show. So, the number of slides allowed has been increased to 10.
The menu order for the post type has now been introduced, so that the slideshow can be ordered by this menu order ascending. The menu order as been headed in the edit section as 'Slide Order'. It can be edited by Quick Edit.
A problem with the sizing of images was corrected.
The featured image box has been moved center stage in the admin panel, and the image made nearly full size.
The plugin now features a simple info line, and an optional Link URL, providing a means for visitors to click from the slider to a featured page in the site, or off-site.
Slider content added, to produce a better slider. This involved changing the js file, as well as the post-type declaration.
Some better instructions were added.
A new slider size, for ultra-thin banners, has been produced. This is especially useful with the Gold Bowl theme.
This is the current stable version. It is updateable, using the Github Updater plugin.