| Very Simple Image Gallery Plugin Beispiel06 |
| Geschrieben von: Andreas Berger |
| Sonntag, den 14. März 2010 um 14:52 Uhr |
|
Die angezeigte Galerie entspricht exakt den Beispiel 01, nur enthält der angezeigte Ordner Bilder verschiedenen Formats. Das Resultat: Die Galerie "springt" weil jedes der Bilder die volle zur Verfügung stehende Breite ausnutzt. Ganz anders die nächste Galerie: Den Unterschied macht der - ab Version 1.6.0 zur Verfügung stehende Parameter "max Image Height". Damit wird die maximale Höhe eines Bildes limitiert - und das Problem behoben. Bleibt der Parameter leer, dann wird weiterhin die Breite ganz ausgenützt. Einstellungen im Konfigurationspanel des PluginsUm die Galerien auf der Webseite so zu konfigurieren, werden im Konfigurationspanel des Plugins die folgenden Werte gesetzt:
Code im ArtikelUm die Bilder im Ordner /images/stories/verysimple anzuzeigen, wird im Artikel an der gewünschten Stelle der folgende Code eingegeben: OverridesHat man im Konfigurationspanel andere Einstellungen als die oben angezeigten getroffen und möchte nur diese eine Galerie wie gezeigt konfigurieren, dann kann man den Code um Parameter Overrides (siehe Plugin Howto Code) erweitern. Die Einstellungen für die oben angezeigte Galerie sind:
Für Fragen und Anregungen steht die Kommentarfunktion zur Verfügung. Bitte geben Sie bei Ihrer Frage die verwendete Joomla! Version an und posten Sie bei Problemen - soweit möglich - einen Link zur betroffenen Seite. |
| Zuletzt aktualisiert am Sonntag, den 20. März 2011 um 13:33 Uhr |

I have your plugin installed on my site http://www.polarspas.ca/products.html?page=shop.product_details&flypage=flypage-ask.tpl&product_id=38&category_id=2
I am using this for a number of different products on my site, but for some reason when I click on any of the thumbnails I am redirected to the top product listing page. I would like to disable the click function all together or have it function the same as the rollover function that changes the main image.
Can you please assist me with this issue?
Thanks for your time,
Mike
Hi Mike!
The plugin you are using is not this one (Very Simple Image Gallery) but the CSS Gallery, another gallery plugin of mine. With this plugin, it is not possible to "disable" the onClick-event, because this would be possible using JavaScript only and the plugin works without JavaScript, using pure CSS.
The problem you ran into starts with the fact, that you are using the plugin on a page without SEF-Urls, this means that the individual page has no individual URL (/shop/category/product.html), but is defined by the request-parameters attached to the main URL (shop.html?category=thisone&product=thatone).
To allow the CSS Gallery to work completely without JavaScript, it uses the CSS onhover pseudo classes of links. Because a link has a href, they are all linked to an anchor at the top of the gallery.
This means, if the feature "Links", that uses the thumbnails to link to external targets, is deactivated and somebody clicks on a thumbnail, he is directed to the current page and the top of the gallery.
The problem: an anchor is by definition relative to the "current page" and the browser uses the current URL to determine this page as long as there is no base-href set in the head of the page. If the "base"-href is set, the browser attaches the anchor (#g__0) to the set base-href.
Unfortunately (in this case), Joomla! sets this base-href and it sets it to the URL of the page without the request-parameters which causes the browser to ab-use the anchor as an "external" link.
The solution: there isn't a quick fix for this. Maybe you want to consider using SEF-Urls on your site (which would be a good idea anyway - in my opinion) or you want to have a look at the plugin, the page you put your question belongs to, the "Very Simple Image Gallery". As long as you do not use the feature "links" with empty settings, it comes without this flaw and the next version (1.6.5 - available within the next two weeks), offers the possibility to switch images onhover too.
Best regards
Andreas