Viewing 2 posts - 1 through 2 (of 2 total)
Viewing 2 posts - 1 through 2 (of 2 total)
The topic ‘Iframe not loading correctly with Iframe blocker hook’ is closed to new replies.
Support Forum › Support Forum › GDPR Cookie Compliance › Iframe not loading correctly with Iframe blocker hook
Hi,
I am using the iframe blocker to block video iframes in a custom post template. In order to achieve this, I have used the following function:
apply_filters(‘gdpr_iframe_blocker_filter’, $iframe);
where the $iframe is a string containing the iframe html element.
When cookies are not accepted, the iframe blocker works alright, but if the cookies were already accepted, once the page loads the blocker appears for a few seconds before reloading and showing the actual iframe.
I hope you can help me fix this issue.
Hi there,
Thanks for using our plugins.
You can add the following code snippet to functions.php
add_filter( 'gdpr_init_script_delay', 'gdpr_delay_script_execution', 20, 1 );
function gdpr_delay_script_execution( $ms ) {
return 0;
}
Hope this helps.
The topic ‘Iframe not loading correctly with Iframe blocker hook’ is closed to new replies.
This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.
Strictly Necessary Cookie should be enabled at all times so that we can save your preferences for cookie settings.
If you disable this cookie, we will not be able to save your preferences. This means that every time you visit this website you will need to enable or disable cookies again.