Page 1 of 1

Embed chart on external webpage **solved**

Posted: Wed Jan 26, 2022 12:29 pm
by kristofvt
Hi,
I'm looking for information on how to properly embed a Meteobridge graph on my personal website. I generated the graph, copied the public URL, and now wanted to embed this on my PHP webpage.

Currently I came up with the following approach:

Code: Select all

$url = 'https://admin.meteobridge.com/<complete_link_to_chart>";
$content = file_get_contents($url);
echo $content;
In principle this works, and the graph is nicely shown in the dedicated section on the page. However, while loading the graph, the spinning loading wheel is covering my entire webpage. When it disappears, the graph is in the correct position. What I'd like to accomplish is that this spinning wheel is just confined to the <div> section where the graph is supposed to show up, in order for it to not jeopardize my entire webpage while loading this one little graph.
Any ideas on how to do this?

Thanks,
Kristof

Re: Embed chart on external webpage

Posted: Wed Jan 26, 2022 3:18 pm
by zakos52
You can put the diagram on your page with iframe, as I did on my page.

The code I use is the following

<center><table width="1250">
<td width="1200">
<iframe
name="iframe"
src="https://admin.meteobridge.com/<complete_link_to_chart>"
width="1200"
height="720"
scrolling="auto"
align="CENTER"
style="border:0px outset #FFFFFF "
frameborder="0"
class="wrapper ">
This option will not work correctly. Unfortunately, your browser does not support inline frames.</iframe>
</td>
</table>


I hope I helped you
My web page is https://meteovyronas.gr/en.htm