TomodomoCo / total-slider

A WordPress plugin for creating, editing and removing ‘slides’ with text and images (for a homepage, for example).
GNU General Public License v2.0
7 stars 2 forks source link

Count slides per page #67

Open panchenkodv opened 9 years ago

panchenkodv commented 9 years ago

In my WP read settings I have 5 posts per page. In this case Slider group show me only 5 slides in admin page and on the site. How can I show all slides without change read settings of WP

chrisvanpatten commented 9 years ago

@PeterUpfold should we add 'posts_per_page' => -1 to the $query_args in the get_slides() method?

https://github.com/vanpattenmedia/total-slider/blob/305aaa3e217a9fff2ed5a154c5819b20f938a5bd/includes/class.total-slide-group.php#L208

chrisvanpatten commented 9 years ago

@panchenkodv can you edit the file total-slider/class.total-slide-group.php and add a new line below line 217?

Here's how that looks by default:

            'meta_key'           => 'total_slider_meta_sequence',
        );

Here's what you should change it to:

            'meta_key'           => 'total_slider_meta_sequence',
            'posts_per_page'     => -1,
        );

Note the new line with the posts_per_page setting.

If that works for you, we'll get this added to the plugin code and push a new version!

panchenkodv commented 9 years ago

Yes, it works for me! All sliders are shown in admin panel and on the site. Great thanks!