[Resolved] Dynamically embedding javascript code for an externally sourced widget/iframe
This support ticket is created 3 years, 10 months ago. There's a good chance that you are reading advice that it now obsolete.
This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.
Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.
No supporters are available to work today on Toolset forum. Feel free to create tickets and we will handle it as soon as we are online. Thank you for your understanding.
Tell us what you are trying to do?
I am trying to use a snippet of Javascript code to display a widget from an external source on my site. When I first started working on this project, the code worked, but sometime over the past few weeks it stopped working. I tried working from a clean staging install of wordpress and toolset but still having the same issue. I also tried placing the code directly into the a code block,on a fresh page in the blocks editor and that doesn't work either. I have also tried using shortcode to call in the custom field instead of the raw code, but also get a blank result.
Is there any documentation that you are following?
Sharing this because it's how we originally set it up with help from Toolset. However, what has changed since then is that we have completely gotten rid of the Elementor template we were building on and opted to build with the Toolset content template instead: https://toolset.com/forums/topic/iframe-embed-code-integration-with-elementor/
What is the link to your site? hidden link
Under the heading "Walking and Biking Score – any score over 50 is good" (still working on the navigation so it's probably easier to just scroll to that spot). On the backend we have both a wysiwyg widget dynamically pulling the code from our custom field and a shortcode widget with the shortcode "[types field='walk-bike-score-widget' output='raw'][/types]". Both are returning a blank on the preview of the page.
I would like to know where do you get the code? Is it from a 3rd party service? Can you share the whole snippet so I can check it?
Would you like to allow me temporary access to check it further?
Also
Jamal passed this ticket to me and I'll take care of this ticket.
To ensure the code you shared is not stripped out from the forum post - Can you please share the code provided by walkscore.com on another file sharing service and then I will try to use that code.
Or
I would like to confirm - is the code added to the field "Walk Score Widget" is correct?
=> hidden link