How do I disable scroll of parent element? Example is iframe Privacy Policy link at bottom of page and with it opens, both the iframe and parent element have scroll ability.
Disable Parent Element Scroll while in iframe Lightbox
12 replies · opened Jun 13, 2021
Hello,
Please consider updating the js/plugins.min.js File with the updated one attached to this reply.
This will definitely work fine. Hope this Helps!
Let us know if we can help you with anything else or if you find any further issues.
Thank you! Will this be applied to file in future updates? If so, can you also make sure you get this instance within plugins.lightbox.js in the event AJAX Lazy Loading is being utilized:
if( elType == 'iframe' ) {
element.magnificPopup({
disableOn: Number( elDisableUnder ),
type: 'iframe',
removalDelay: 160,
preloader: false,
fixedContentPos: true
});
}We will add an option to enable/disable this in the Next Update. Something like data-fixed-contentpos="true". If you need us to incorporate this right now, we can provide you with the updated JS Files but we might also add additional options for controlling the Lightbox in the next update.
Let us know your preferences regarding this and we will definitely accommodate them.
Just checking to make sure it gets rolled in at update if using AJAX Lazy Loading. I am good as-is for now, nothing else needed right now. Thanks for fast responses!
Very Happy to Help! :) These updates will definitely be included and also the next update will include the Mobile Transparent Headers. :)
Meanwhile, please do let us know if we can help you with anything else.
Just applied version 6.6 and I should've noted by now...I still have to update the plugins.min.js manually with each update to reflect not scrolling when an iframe is active. Can you update the plugins.min.js code in the next update from this:
"iframe"==c&&a.magnificPopup({disableOn:Number(d),type:"iframe",removalDelay:160,preloader:!1,fixedContentPos:!1}
to this:
"iframe"==c&&a.magnificPopup({disableOn:Number(d),type:"iframe",removalDelay:160,preloader:!1,fixedContentPos:!0}
AND also plugins.js from this:
if( elType == 'iframe' ) {
element.magnificPopup({
disableOn: Number( elDisableUnder ),
type: 'iframe',
removalDelay: 160,
preloader: false,
fixedContentPos: false
});
}to this:
if( elType == 'iframe' ) {
element.magnificPopup({
disableOn: Number( elDisableUnder ),
type: 'iframe',
removalDelay: 160,
preloader: false,
fixedContentPos: true
});
}Thanks
Hello,
That's correct! Just applying the fixedContentPos:!0 will work fine. We are definitely making this hassle-free in Canvas 7, with only one file to change. No more js/plugins.js or js/plugins.min.js Files.
Hope this Helps!
Let us know if we can help you with anything else or if you find any further issues.
This has not yet been incorporated into version 6.6.1 released today or was it incorporated another way?
Hello,
This Option has not yet been incorporated as this update is still under Canvas v6.x, so you will still need to make this change manually. This is possibly the Last update for Canvas v6.x and this Option is set to be incorporated with Canvas 7.
Hope this Helps!
Let us know if we can help you with anything else or if you find any further issues.
How is this taken care of now in version 7? Below URL is where I need to apply it to.
Hello,
We have already added this feature in the latest update and it will be available shortly for download. We will send you an email notifying about the update. Thanks for your Patience.
You can then simply apply data-content-position="fixed" to the data-lightbox Element.
Meanwhile, do let us know if we can help you with anything else or if you find any further issues with Canvas.
Solved with 7.0.2, thanks!
Have the same question, or something new?
Sign in to the Canvas dashboard to reply or open your own topic. Canvas owners get direct help from the SemiColonWeb team.
Reply on the dashboard