This plugin hasn’t been tested with the latest 3 major releases of WordPress. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.

SX Bootstrap Carousel

Lýsing

A custom post type for choosing images and content which outputs a carousel from Twitter Bootstrap using the shortcode [sx-carousel].

The plugin assumes that you’re already using Bootstrap, so you need to load the Bootstrap javascript and CSS separately.

If you’d like to contribute to this plugin, you can find it hosted on GitHub.

Shortcode Options

If you’d like different settings for different carousels, you can override these by using shortcode options…

  • interval (default 5000)

    • Length of time for the caption to pause on each image. Time in milliseconds.
      [sx-carousel interval=“12000″]
  • showcaption (default true)

    • Whether to display the text caption on each image or not. true or false.
      [sx-carousel showcaption=“false“]
  • showcontrols (default true)

    • Whether to display the control arrows or not. true or false.
      [sx-carousel showcontrols=“false“]
  • orderby and order (default menu_order ASC)

    • What order to display the posts in. Uses WP_Query terms.
      [sx-carousel orderby=“rand“]
      [sx-carousel orderby=“date“ orderby=“DESC“]
  • category (default all)

    • Filter carousel items by a comma separated list of carousel category slugs.
      [sx-carousel category=“homepage,highlights“]
  • id (default all)

    • Specify the ID of a specific carousel post to display only one image.
    • Find the image ID by looking at the edit post link, eg. post 109 would be /wp-admin/post.php?post=109&action=edit
      [sx-carousel id=“109″]
  • twbs (default 2)

    • Output markup for Twitter Bootstrap Version 2 or 3.
      [sx-carousel twbs=“3″]

Contributing

If you would like to contribute to this plugin, please go to the GitHub repository and make a personal fork of the development version. You can then make your changes and submit a pull request. I will happily review the code and then merge when we’re both happy. You can read more details here.

Skjámyndir

  • Admin list interface showing Carousel images and titles.
  • Admin image interface showing optional title and caption (Excerpt) fields, along with Category, order, image and URL
  • Admin Screen for Settings Carousel
  • Example output. Requires Bootstrap CSS and Javascript to be loaded (see documentation).

Uppsetning

The easy way:

  1. Go to the Plugins Menu in WordPress
  2. Search for „SX Bootstrap Carousel“
  3. Click ‘Install’
  4. Activate the plugin

Manual Installation

  1. Download the plugin file from this page and unzip the contents
  2. Upload the sx-bootstrap-carousel folder to the /wp-content/plugins/ directory
  3. Activate the sx-bootstrap-carousel plugin through the ‘Plugins’ menu in WordPress

Once Activated

  1. Make sure that your theme is loading the Twitter Bootstrap CSS and Carousel javascript
  2. Place the [sx-carousel] shortcode in a Page or Post
  3. Create new items in the Carousel post type, uploading a Featured Image for each.
    1. Optional: You can hyperlink each image by entering the desired url Image Link URL admin metabox when adding a new carousel image.

SOS

The carousel doesn’t start sliding itself / setting interval doesn’t work

This can be caused by having your jQuery and Bootstrap javascript files included in the wrong place.

  • Make sure that jQuery is only being included once
  • Make sure that the Bootstrap javascript file is being included after jQuery
    • NB: This often means putting it after wp_head() in your theme’s header.php file
  • Make sure that both jQuery and Bootstrap are being included in the theme header, not footer
  • Make sure that the Bootstrap javascript file is referenced after the jQuery file.
How do I insert the carousel?

First of all, install and activate the plugin. Go to ‘Carousel’ in the WordPress admin pages and add some images. Then, insert the carousel using the [sx-carousel] into the body of any page.

Can I insert the carousel into a WordPress template instead of a page?

Absolutely – you just need to use the do_shortcode WordPress function. For example:

I get grey bars at the side of my images / The image isn’t aligned (or doesn’t reach the far side of the carousel)

This happens when the carousel is bigger than your images. Either upload higher resolution images, or select the „Use background images?“ option in the settings (this will stretch the images though, so they may get a little blurry).

Can I change the order that the images display in?

You can specify the order that the carousel displays images by changing the setting in the Settings page, or by using the orderby and order shortcode attributes. The settings page has common settings, or you can use any terms described for the WP_Query orderby terms for the shortcode.

Can I have different carousels with different images on the same site?

Yes – create a few categories and add your specific images to a specific category. Then, when inserting the shortcode into the page, specify which category you want it to display images from using the category shortcode attribute.

Can I customise the way it looks / works?

The carousel shortcode has a number of attributes that you can use to customise the output. These are described on the main plugin Description page.

Help! Nothing is showing up at all
  1. Is the plugin installed and activated?
  2. Have you added any items in the Carousel post type?
  3. Have you placed the [sx-carousel] shortcode in your page?

Try writing the shortcode using the ‘Text’ editor instead of the ‘Visual’ editor, as the visual editor can sometimes add extra unwanted markup.

My images are showing but they’re all over the place

Is your theme loading the Bootstrap CSS and Javascript? (look for bootstrap.css in the source HTML)

The carousel makes the content jump each time it changes

You need to make sure that each image is the same height. You can do this by setting an Aspect ratio in the Edit Image section of the WordPress Media Library and cropping your images.

Umsagnir

There are no reviews for this plugin.

Þátttakendur & höfundar

“SX Bootstrap Carousel&#8221 er opinn hugbúnaður. Eftirfarandi aðilar hafa lagt sitt af mörkum við smíði þessarar viðbótar.

Höfundar

Breytingarsaga

1.0

  • Initial release