How I integrated iframemanager into WordPress (and ACF). #64
KingWebsites
started this conversation in
Show and tell
Replies: 1 comment
-
Here's my routine for replacing Google Map iframes added to WYSIWYG fields with iframemanager compliant code. I am also using Google Maps elsewhere on my site that are not iframed, but instead use the https://maps.googleapis.com/maps-api-v3 library. These do not seem to leave any cookies on the browser so I can ignore them for now.
Quick note. This code works for iFrames that are copied direct from the Google Maps share functionality. This will not work on maps that use the /maps/embed/v1/place + API KEY. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I thought I'd share my code for how I change YouTube videos that have been added to WordPress to the format required by iframemanager. This detects oEmbed links and actual iframes added to the WordPress WYSIWYG area or ACF fields (WYSIWYG & oEmbed field types). This has not been tested on Guttenberg blocks, just Classic Editor WYSIWYG and ACF fields.
I would be grateful for any improvement ideas or any additional services. I have added it here as I thought it was the best place. Let me know if you think it should be elsewhere, or even it its own repo.
FYI: I am using the Pressidium Cookie Consent plugin, which uses CookieConsent v2, to connect this with my WP site's cookie compliance system.
Beta Was this translation helpful? Give feedback.
All reactions