Johannes Kinast
Forum Replies Created
-
Hi @aduwow,
Unfortunately, there is no easy function like
get_post_gallery()for images. A solution would be to parse the html output and check for an image there, but it’s quite expensive on long posts.You can use the filter
baguettebox_enqueue_assetsto implement such a check. If you have many posts with images where you need the gallery, just use this:add_filter( 'baguettebox_enqueue_assets', '__return_true' );Hi @charlie67p,
I think this feature must be implemented through baguetteBox.js.
I have no easy solution here. You can change the selector in your functions.php, see https://github.com/goaround/gallery-block-lightbox/blob/cb31689d429664d8e8166e9aad0ba412d4587f30/gallery-block-lightbox.php#L32 or add a .no-lightbox to images with a Wikipedia .jpg link
Forum: Plugins
In reply to: [Lightbox for Gallery & Image Block] Custom post templateYou need to add a CSS selector to the <a> element e.g.
add_filter( 'baguettebox_selector', function( $selector ) { return $selector . ',.my-gallery'; } )And make sure the scripts and styles are loaded e.g. with this snipped in your functions.php:
add_filter( 'baguettebox_enqueue_assets', '__return_true' );Forum: Plugins
In reply to: [Lightbox for Gallery & Image Block] Custom post templateThen provide me with the template.
You can add your own CSS selector: https://ww.wp.xz.cn/plugins/gallery-block-lightbox/#how%20can%20i%20add%20my%20own%20block%3F%20%2F%20can%20i%20change%20the%20css%20selector%3F
And make sure the assets are enqueuend: https://ww.wp.xz.cn/plugins/gallery-block-lightbox/#how%20to%20enqueue%20the%20necessary%20assets%20%28script%20%26%20style%29%20for%20blocks%20outside%20of%20posts%20or%20for%20block%20types%20that%20are%20not%20supported%20by%20default%3F
More details about the Lightbox here: https://github.com/feimosi/baguetteBox.js
Forum: Plugins
In reply to: [Lightbox for Gallery & Image Block] Custom post templateHi @ferda2,
Please provide an example URL.
Forum: Plugins
In reply to: [Lightbox for Gallery & Image Block] Issue with SVN tagsHi @travisweston,
I just tagges 1.16.1
Hi @oldrup,
This plugin includes the baguettBox.js library. I am not the maintainer of the library. Please feel free to provide a PR there: https://github.com/feimosi/baguetteBox.js I think the best solution would be to provide the aria-labels via an option. I would set the translation then server-side.
Hi John,
For galleries, you have to set the link for each image, see this screenshot: https://ps.w.org/gallery-block-lightbox/assets/screenshot-3.png?rev=3259762
Hallo Gerhard,
ich antworte dir einfach mal auf Deutsch 😉
Aktuell sehe ich in den Galerien leider garkeine Links. Nur die Bilder.
Das Problem mit den Links von Nextcloud wird aber sein, dass diese keine Dateiendung haben z.B. .jpg oder .png. Grundsätzlich könntest du den
baguettebox_filterdafür nutzen, um auch die Links zu deiner Nextcloud in der Lightbox zu öffnen: https://github.com/goaround/gallery-block-lightbox/blob/243c5d9d055906ac2e9d45f1969778918721eb59/gallery-block-lightbox.php#L32
Wird aber trotzdem leider kompliziert mit der URL-Struktur von Nextcloud.Btw: schöne Impressionen aus Turin. Ich habe die Stadt bei meinem kurzen Besuch 2011 auch sehr gemocht und muss da mal wieder hin!
Forum: Plugins
In reply to: [Lightbox for Gallery & Image Block] Images in gallery do not auto re-sizeHi @yavimatuzalem,
This is a CSS issue of your Theme and has nothing to do with this plugin. This plugin does not change the CSS of the Gallery or Image.
Forum: Plugins
In reply to: [Lightbox for Gallery & Image Block] Double visionHi @kdougas,
You have two lightbox active. This plugin and Elementor Lightbox: https://elementor.com/help/lightbox/
It’s a bit hidden, use the right arrow to open this menu:

Hi @neuralstasis,
You can add the CSS class
no-lightboxto the image link. Not to the image! Then the lightbox will not apply to this image.Forum: Plugins
In reply to: [Lightbox for Gallery & Image Block] Multiple galleries@fabricios see this post about the functions.php: https://kinsta.com/blog/wordpress-functions-php/
If you don’t have a Child Theme you can use a Snippets Plugin as well e.g. https://ww.wp.xz.cn/plugins/code-snippets/ but I see this as a security issue.