WordPress.org

Ready to get started?Download WordPress

Forums

Recent Posts Slider
Using Multiple Sliders on Same Page (2 posts)

  1. joelp3d
    Member
    Posted 1 year ago #

    I am wondering if it is possible to add multiple sliders on the same page with different categories, title background colors and pagination rules.

    Here is what my I am trying to do.
    1) Have the top rps slider as a scrolling slider
    2) Have 4 more sliders on the same page that are static with no pagination and each with different title background colors

    Thanks in advance!

    Joe

    http://wordpress.org/extend/plugins/recent-posts-slider/

  2. SlagdropAdmin
    Member
    Posted 1 year ago #

    What you want to do is repeat the function multiple times in your template.

    <table border="0" style="padding:4px;" width="100%" cellspacing="0" cellpadding="0">
      <tr>
        <td class="featured-box" style="padding:0;">
    <?php if (function_exists('rps_show')) echo rps_show($category_ids="4", $total_posts="1", $post_include_ids, $post_exclude_ids); ?>
        </td>
        <td class="featured-box" style="padding:0;">
    <?php if (function_exists('rps_show')) echo rps_show($category_ids="5", $total_posts="1", $post_include_ids, $post_exclude_ids); ?>
        </td>
        <td class="featured-box" style="padding:0;">
    <?php if (function_exists('rps_show')) echo rps_show($category_ids="2", $total_posts="1", $post_include_ids, $post_exclude_ids); ?>
        </td>
      </tr>
    </table>

    Something like the above will give you 3 sliders, though the current settings are pulling from only one category ID.

    If you want the top slider to show multiple posts, change the number of posts (to 3, 5, or whatever) and if you want it to pull from multiple categories, just add $category_ids="2, 3, 5" or whatever you want to do.

    As far as changing the styling for each one, do that in CSS. Just put each box in a different div, or create a div #RPS and then multiple classes .box1, .box2 et cetera, and style everything that way.

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic