-
AuthorPosts
-
February 3, 2016 at 12:54 pm #577083
Hi,
we are using the Envira gallery plugin which creates a lightbox effect when you click on an image. But when you close the image you can see the default WordPress/Enfold lightbox image behind it,
How do we disable this and keep the plugin effect?
The codeblock containing the plugin shortcode is contained within a colour section with the ID: #portfolio_page.
I’ve tried disabling the pointer-events using:
#portfolio_page {pointer-events: none;} but this removed all pointer effects.
The site in question is at: EnaMay Photography
Thanks,
- This topic was modified 8 years, 10 months ago by DigitalEssence.
February 3, 2016 at 6:40 pm #577251Hi DigitalEssence!
Please go to Enfold theme options and uncheck “Lightbox Modal Window” to disable built in lightbox.
Regards,
YigitFebruary 3, 2016 at 6:42 pm #577254Hi Yigit,
Thanks for your reply.
that would disable it for the entire site whereas we will require that feature outwith the portfolio page.
Is there a way to target just this page?
February 3, 2016 at 6:47 pm #577257Hi!
Please go to Enfold/js and open avia.js file and find
exclude : '.noLightbox, .noLightbox a, .fakeLightbox, .lightbox-added, a[href*="dropbox.com"]',
and change it to
exclude : '#portfolio_page a, #portfolio_page, .noLightbox, .noLightbox a, .fakeLightbox, .lightbox-added, a[href*="dropbox.com"]',
If you are using a child theme, please add following code to Functions.php file of your child theme
function wp_change_aviajs() { wp_dequeue_script( 'avia-default' ); wp_enqueue_script( 'avia-default-child', get_stylesheet_directory_uri().'/js/avia.js', array('jquery'), 2, true ); } add_action( 'wp_print_scripts', 'wp_change_aviajs', 100 );
and move modified file inside /js folder
Cheers!
YigitFebruary 3, 2016 at 7:07 pm #577270Brilliant, thank you.
That’s all sorted. I’ll add this to my Gist as well in case I need it in the future.
February 3, 2016 at 7:13 pm #577273Hi!
You are welcome, glad we could help :)
Let us know if you have any other questions or issuesRegards,
YigitSeptember 3, 2016 at 2:11 am #681500Searching brought me to this thread, solution seems great, but how can I modify this to disable the lightbox for just all posts, and keep the lightbox active for all pages?
Hi!
Please go to Enfold/js and open avia.js file and find
exclude : '.noLightbox, .noLightbox a, .fakeLightbox, .lightbox-added, a[href*="dropbox.com"]',
and change it to
exclude : '#portfolio_page a, #portfolio_page, .noLightbox, .noLightbox a, .fakeLightbox, .lightbox-added, a[href*="dropbox.com"]',
September 3, 2016 at 2:17 am #681501OH, I think I got it. Enfold support, can you please tell me if this looks right? Trying to deactivate the lightbox on only posts:
Replaced with the following:
exclude : '.single-post a, .single-post, .noLightbox, .noLightbox a, .fakeLightbox, .lightbox-added, a[href*="dropbox.com"]',
- This reply was modified 8 years, 3 months ago by enfold4phil.
September 4, 2016 at 8:57 am #681762Hi @enfold4phil,
I can’t see anything wrong with your code, is it working out for you?
Thanks,
RikardSeptember 4, 2016 at 3:19 pm #681802Thanks Rikard for confirming, the code is working well :) Hope this helps some Googlers
September 4, 2016 at 6:47 pm #681829Hey!
Please do not hesitate to create a new ticket for us, if you need anything else.
Thanks a lot
Cheers!
Basilis -
AuthorPosts
- The topic ‘How do I disable WordPress/Enfold Lightbox but retain plugins lightbox effect?’ is closed to new replies.