Imagescroller_XH
Moderator: Tata
Re: Imagescroller_XH
Hi
Thanks for quick replay (agen)
It works perfect!
thanks
Thanks for quick replay (agen)
It works perfect!
thanks
Re: Slideshow_XH
In planning, yes, but that is since a long time... Sorry.Korvell wrote:Maybe there's a mix of both plugins in the planning ?
+1maeg wrote:Slideshow dosen't support that option, try flexslider xh
Last edited by cmb on Mon Apr 28, 2014 9:51 pm, edited 2 times in total.
Reason: moved this and the following posts from ./viewtopic.php?f=12&t=5525&p=41076#p41076
Reason: moved this and the following posts from ./viewtopic.php?f=12&t=5525&p=41076#p41076
Christoph M. Becker – Plugins for CMSimple_XH
Re: Slideshow_XH
That could be easily accomplished. Have a look at plugin/imagescroller/index.php. There are two functions that build an array of images: imagescroller_images_from_dir() and imagescroller_images_from_file(), where it would be possible to randomize the arrays:Korvell wrote:I know it's possible with Imagescroller_XH, but I wish for my images to show randomized.
Code: Select all
function imagescroller_images_from_dir($dir) {
...
natcasesort($imgs); // remove this line
shuffle($imgs); // insert this line
return $imgs;
}
...
function imagescroller_images_from_file($fn) {
...
shuffle($res); // insert this line
return $res;
}
Christoph M. Becker – Plugins for CMSimple_XH
Re: Slideshow_XH
The modification of index.php for Imagescroller_XH works, but then it works just like Slideshow_XH - showing the images randomized. If I call Imagescroller_XH with the data file option supplying links for the images the images doesn't show randomized but in the order they are listed in the data file. Then it's just the same as Slideshow_XH apart from the link.
Tested the flexslider, but it doesn't really work for me - the images are all just shown at once in a long vertical list...
I'll stick with Slideshow_XH for now and use a separate page with links for all the images.
Tested the flexslider, but it doesn't really work for me - the images are all just shown at once in a long vertical list...
I'll stick with Slideshow_XH for now and use a separate page with links for all the images.
Re: Slideshow_XH
Hm, that should have been solved by the second mofication. The complete function:Korvell wrote:If I call Imagescroller_XH with the data file option supplying links for the images the images doesn't show randomized but in the order they are listed in the data file.
Code: Select all
function imagescroller_images_from_file($fn) {
$dir = dirname($fn).'/';
$data = file_get_contents($fn);
$data = str_replace(array("\r\n", "\r"), "\n", $data);
$recs = explode("\n\n", $data);
foreach ($recs as $rec) {
$rec = array_map('trim', explode("\n", $rec));
$rec[0] = $dir.$rec[0];
$res[] = $rec;
}
shuffle($res);
return $res;
}
That's most likely caused by a JavaScript error. If you like, you can have a look at the Error/JavaScript console of your browser (F12 -> ... depending on the browser).Korvell wrote:Tested the flexslider, but it doesn't really work for me - the images are all just shown at once in a long vertical list...
Christoph M. Becker – Plugins for CMSimple_XH
Re: Slideshow_XH
Ouch - my mistake - a copy'n'paste mistake
Now it works just fine showing the images randomly with link. Btw - modified the index.php so that the links are opened in a new window (a suggestion for the next version )
Now I just need a simple way to turn off the navigation buttons - don't need that and I feel they do get in the way because my images are just about 180x110 px.
Now it works just fine showing the images randomly with link. Btw - modified the index.php so that the links are opened in a new window (a suggestion for the next version )
Now I just need a simple way to turn off the navigation buttons - don't need that and I feel they do get in the way because my images are just about 180x110 px.
Re: Slideshow_XH
Make them "display:none" in plugin stylesheet.
CMSimple.sk
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.
Re: Slideshow_XH
Or use transparent 1x1 px PNGs instead (replace the respective images in plugins/imagescroller/images/): http://commons.wikimedia.org/wiki/File:1x1.pngTata wrote:Make them "display:none" in plugin stylesheet.
Christoph M. Becker – Plugins for CMSimple_XH
Re: Slideshow_XH
Changed .show into .hide in this line of the plugins' index.php:
into
Works like a charm and I'm happy Thank You all!
PS: If I would need the original Imagescroller_XH plugin functionality somewhere else on my site - could I then simply make a copy of the plugin folder and name it differently?
Code: Select all
$(this).find('img.imagescroller_prev, img.imagescroller_next, img.imagescroller_play, img.imagescroller_stop').show()
Code: Select all
$(this).find('img.imagescroller_prev, img.imagescroller_next, img.imagescroller_play, img.imagescroller_stop').hide()
PS: If I would need the original Imagescroller_XH plugin functionality somewhere else on my site - could I then simply make a copy of the plugin folder and name it differently?
Re: Slideshow_XH
Or maybe a new variable in config.php:
Code: Select all
$plugin_cf['imagescroller']['navig']="0"; //0 = hide, 1 = show
CMSimple.sk
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.
It's no shame to ask for an answer if all efforts failed.
But it's awful to ask without any effort to find the answer yourself.