2014-08-28, 01:53:26
Hi kate!
Unfortunately there is no 'shortcode' way to pre-select default values. (Or maybe I'm not familiar with the i18n_gallery enough). And you're right, you'll have to hack the plugin file, but it's not complicated at all.
See the plugin_nivoSlider.php (as of 0.9.4) file at lines 19-23:
Simply put the "option" line for the theme you want as first and it will be selected when you create a gallery (or select nivoSlider for an existing gallery for the first time).
Anyway, I think I'll use the 'default' theme as default in the next version. So thank you for pointing to this.
The plugin includes theme css file even when css is off. That's a bug, of course.
But there's a more serious problem with css - nivoSlider doesn't work correctly without it's main css file (too many important parameters there). I had to mention that on the download page but I forgot
If you're in a hurry I would advise you to (1) turn on css (otherwise it won't work anyway)
(2) select a theme and edit its css to customize the slider
Meanwhile, I'm working on this problem (moving crucial parameters from css to php), maybe I'll get it done by this weekend I hope.
Thanks for your response!
(2014-08-27, 22:23:36)kate Wrote: - the default template is "bar", is there any way to change it in the shortcode or do I need to hack the plugin file?
Unfortunately there is no 'shortcode' way to pre-select default values. (Or maybe I'm not familiar with the i18n_gallery enough). And you're right, you'll have to hack the plugin file, but it's not complicated at all.
See the plugin_nivoSlider.php (as of 0.9.4) file at lines 19-23:
Code:
<option value="bar" <?php echo @$gallery['theme'] == 'bar' ? 'selected="selected"' : ''; ?>> bar </option>
<option value="dark" <?php echo @$gallery['theme'] == 'dark' ? 'selected="selected"' : ''; ?>> dark </option>
<option value="default" <?php echo @$gallery['theme'] == 'default' ? 'selected="selected"' : ''; ?>> default </option>
<option value="light" <?php echo @$gallery['theme'] == 'light' ? 'selected="selected"' : ''; ?>> light </option>
<option value="nano" <?php echo @$gallery['theme'] == 'nano' ? 'selected="selected"' : ''; ?>> nano </option>
Anyway, I think I'll use the 'default' theme as default in the next version. So thank you for pointing to this.
(2014-08-27, 22:23:36)kate Wrote: - switching off the CSS in the gallery settings doesn't affect the NivoSlider so is it possible to unhook the stylesheet?
The plugin includes theme css file even when css is off. That's a bug, of course.
But there's a more serious problem with css - nivoSlider doesn't work correctly without it's main css file (too many important parameters there). I had to mention that on the download page but I forgot
If you're in a hurry I would advise you to (1) turn on css (otherwise it won't work anyway)
(2) select a theme and edit its css to customize the slider
Meanwhile, I'm working on this problem (moving crucial parameters from css to php), maybe I'll get it done by this weekend I hope.
Thanks for your response!