greencode
Member
Posted 2 years ago #
The plugin's great but I think it would really benefit from having a Random function. Is there any way that I can quickly add this to the wp-cycle.php page? I notice the word "random" appears in the jquery.cycle.all.min.js file so I'm presuming it'd be fairly straight-forward to add?
http://wordpress.org/extend/plugins/wp-cycle/
Hi, I solved it by the shuffle php function.
I put the shuffle($wp_cycle_images); on line 407 in wp-cycle.php before the foreach function begins:
406 echo '<div id="'.$wp_cycle_settings['div'].'">'.$newline;
407 shuffle($wp_cycle_images);
408 foreach((array)$wp_cycle_images as $image => $data) {
409...
That will randomize the order of the images in the html file... give it a try.
It works for me.
greencode
Member
Posted 2 years ago #
Sorry for taking so long to get back (I wish there was some kind of notification system on WordPress Support!). I'll give this a try next week, when I'm back in the office, and let you know how I get on.
greencode
Member
Posted 2 years ago #
Hi tric3x. Finally got around to implementing this today and it works perfectly - really great addition to an already simple and great plugin. Thanks.
marknesss
Member
Posted 2 years ago #
Upon adding the shuffle function, I lost my ability to delete slides. Any one else experiencing this?
lindebjerg
Member
Posted 1 year ago #
Super adon, just what I was looking for:-) and I can still delete slides.
Asdrubal
Member
Posted 1 year ago #
Thanks trix3x! I imagined this and you are here with the solution! XD