Welcome, Guest
Username: Password: Remember me
  • Page:
  • 1
  • 2

TOPIC: Group Images for Lightbox

Group Images for Lightbox 2 years 3 months ago #675

  • lemonmagic
  • lemonmagic's Avatar
  • Offline
  • Новый участник
  • Posts: 5
Is it possible to group images for Lightbox View.
Currently if guests are looking at a category-blog view, within the Lightbox they can switch through all Images which are processed on the Page. Depending on the Content this can be very confusing.

Therefore I would like to set each Image within an Article to the same Group,
something like
<img url="/images/image.jpg" class="mavik-thumbnail" data-group="Article21" width="150" height="300" />
so only Images within the same Group are shuffled inside of the Lightbox
The administrator has disabled public write access.

Group Images for Lightbox 2 years 3 months ago #680

  • mavik
  • mavik's Avatar
  • Offline
  • Администратор
  • Posts: 121
  • Thank you received: 21
But now images have group id. Example for Slimbox:

<a href="/thumbnail/images/sampledata/fruitshop/apple.jpg" class="thumbnail zoomin" style="" rel="lightbox-6" title="Apple"><img src="/thumbnail/images/thumbnails/images/sampledata/fruitshop/apple-fit-218x163.jpg" alt="Яблоки" class="" style="" height="163" width="218"></a>
The administrator has disabled public write access.

Group Images for Lightbox 2 years 3 months ago #681

  • lemonmagic
  • lemonmagic's Avatar
  • Offline
  • Новый участник
  • Posts: 5
Just switched to Slimbox, and yes there is a "rel" tag now.
But can we change the Value for our Images manually?

Checking on my Site with Slimbox, opening a Blog View with many Articles, Slimbox pops up with 28 Images in Line, all having the same group ID..

For Example, if you run a Website about different Fruits, I would like to set group ID's to Images with the same Fruit, like "Apple" & "Pears"
The administrator has disabled public write access.

Group Images for Lightbox 2 years 2 months ago #684

  • mavik
  • mavik's Avatar
  • Offline
  • Администратор
  • Posts: 121
  • Thank you received: 21
Give me link to your site.
The administrator has disabled public write access.

Group Images for Lightbox 2 years 2 months ago #685

  • lemonmagic
  • lemonmagic's Avatar
  • Offline
  • Новый участник
  • Posts: 5
You can check an example here:

2015.schoenruh.com/de/zimmer/zimmer-suiten

Rooms are grouped into Tabs, and the Lightbox shifts through all Rooms which is confusing,
so I would like to group Images "room1", "room2" , "room3", ...
The administrator has disabled public write access.

Group Images for Lightbox 2 years 2 months ago #686

  • mavik
  • mavik's Avatar
  • Offline
  • Администратор
  • Posts: 121
  • Thank you received: 21
It's not blog of articles, it's one article. So plugin groups all images to one group.
You can change it in your template.
1. Set attribute data-group="<group id>" for images
2. Copy files from plugins/content/mavikthumbnails/tmpl
to templates/<your template>/html/plg_content_mavikthumbnails
3. Edit file templates/<your template>/html/plg_content_mavikthumbnails/magnific.php:
replace
$html .= '<a href="'.$this->info->original->url.'" class="'.$class.' zoomin magnific-popup-'.$this->plugin->item->id.'" style="'.$this->linkStyle.'" title="'.$this->image->getAttribute('alt').'">';
to
$groupId = $this->image->getAttribute('data-group');
$html .= '<a href="'.$this->info->original->url.'" class="'.$class.' zoomin magnific-popup-'.$groupId.'" style="'.$this->linkStyle.'" title="'.$this->image->getAttribute('alt').'">';
The administrator has disabled public write access.
  • Page:
  • 1
  • 2
Time to create page: 0.239 seconds
Powered by Kunena Forum