I'm trying to embed a chart from Venngage to a tab located in Layout. It doesn't save.
Sample code:
<script src="<em><u>hidden link</u></em>" data-vg-id="8AXMpBSp1yA" data-title="Cboe Volatility Index" data-w="640" data-h="430" data-multipage="true" data-f="false"></script>
Hello and thank you for contacting the Toolset support.
I’m not sure yet how you are trying to add the script tag you shared within the tab.
If you can tell me what Layout cell you are using and where exactly you are trying to add the script tag, once I know, I will be in a better position to guide you in the right direction.
There are many ways to add a script tag. As a workaround, you can either:
Add a content template cell and with the content template cell, you will find the JS editor box where you can add the script tag.
- Add the script using a custom shortcode, and use the shortcode inside the layout. Check this documentation https://developer.wordpress.org/themes/functionality/widgets/
- Add the script to a widget in Appearance->Widgets, and then use a widget cell on your layout. Check this article https://toolset.com/documentation/user-guides/layouts/widget-area-cell/
I hope this helps. Let me know if you have any doubts.
Hi, I added the script to a template inserted inside an editor cell on layout. Now the problem is it not working properly, only 1 chart/script is showing. Is it possible to add more than one on a page?
Editor cell content:
<div id="div-econforecast1">
<div style="background-color:#192e43; color:white; padding:10px 15px;">
<p style="font-weight:bold; font-size:15px; margin-bottom:0px;">Economic Forecast</p>
</div>
<div id="div-econforecast2">
<div class="tab">
<button class="tablinks active" onclick="openCity(event, 'GDP')">GDP</button>
<button class="tablinks" onclick="openCity(event, 'Employment')">Employment</button>
<button class="tablinks" onclick="openCity(event, 'Currency')">$ vs Currencies</button>
<button class="tablinks" onclick="openCity(event, 'Treasury')">10-Y Treasury Yield</button>
<button class="tablinks" onclick="openCity(event, 'VIX')">VIX</button>
</div>
<div id="GDP" class="tabcontent" style="display:block">
[wpv-post-body view_template="vix-chart"]
</div>
<div id="Employment" class="tabcontent">
<h3>Employment</h3>
<p>.</p>
</div>
<div id="Currency" class="tabcontent">
<h3>$ vs Currencies</h3>
<p>.</p>
</div>
<div id="Treasury" class="tabcontent">
[wpv-post-body view_template="10y-treasury-yield
"]
</div>
<div id="VIX" class="tabcontent">
<p style="font-weight:bold; margin-bottom:0px; font-size:14px;">Cboe Volatility Index</p>
[wpv-post-body view_template="vix-chart"]
</div>
</div>
</div>
Script inside the template:
<script src="<em><u>hidden link</u></em>" data-vg-id="8AXMpBSp1yA" data-title="Cboe Volatility Index" data-w="640" data-h="430" data-multipage="true" data-f="false"></script>
I am not sure how Venngage infographics work, I could not find any online documentation. But I am pretty sure each <script> tag adds only one infographic because it uses an attribute "data-vg-id="ID_OF_THE_GRAPHIC"".
I would say that you will need to add a <script> tag for each infographic you want to add.
If this does not help, please allow me temporary access to your website(WordPress/FTP). Tell me where are you using infographics and what infographics you want to add. Please add any online documentation about Venngage that you are using.
*** Please make a FULL BACKUP of your database and website.***
Your next reply will be private to share credentials safely.
Closing this ticket for now. Thanks!