Hello!
I want to create a simple (bootstrap) image lightbox galery but for some reason it doesn't work out the way I want.
It should be hooked upon some simple HTML code that includes an image tag as thumbnail + a link to the main image which opens as lightbox (doesn't need any cropping at all, Lightbox plugin takes care). This HTML part should simply be repeated:
This is my couch code:
For some reason the a-tag links to gg_thumb (thumbnail) but should link to gg_image (full image without cropping). However img tag remains completey empty. No src="" is added (checked with browser inspector) Besided that, I would like to be able to switch cropping from middle, left, right etc. like it is explained in the documentation.
Any ideas?
Thank you very much!
Best regards,
Pierre
I want to create a simple (bootstrap) image lightbox galery but for some reason it doesn't work out the way I want.
It should be hooked upon some simple HTML code that includes an image tag as thumbnail + a link to the main image which opens as lightbox (doesn't need any cropping at all, Lightbox plugin takes care). This HTML part should simply be repeated:
- Code: Select all
<cms:show_repeatable 'galery'>
<a href="<cms:show gg_image />" data-toggle="lightbox" data-gallery="gallery" class="col-md-3"> <img src="<cms:show gg_thumb />" class="img-fluid rounded" /> </a>
</cms:show_repeatable>
This is my couch code:
- Code: Select all
<cms:repeatable 'galery'>
<cms:editable
name="gg_image"
label="Image"
desc="Upload your main image here"
show_preview='1'
type="image"
/>
<cms:editable
name="gg_thumb"
assoc_field="gg_image"
label="Image Thumbnail"
desc="Thumbnail of image above"
width='500'
height='500'
enforce_max='1'
type="thumbnail"
crop="1"
/>
</cms:repeatable>
For some reason the a-tag links to gg_thumb (thumbnail) but should link to gg_image (full image without cropping). However img tag remains completey empty. No src="" is added (checked with browser inspector) Besided that, I would like to be able to switch cropping from middle, left, right etc. like it is explained in the documentation.
Any ideas?
Thank you very much!
Best regards,
Pierre