Community
OpenEnergyMonitor

OpenEnergyMonitor Community

Embedding MySolar (and other apps) into websites

Tags: #<Tag:0x00007fc9b08c6ca8> #<Tag:0x00007fc9b08c6910>

Hi everyone,

I know how to embed my dashboards into other websites, but is there a way to cleanly do so with My Solar, et cetera?

I’m using HABPanel and want to view My Solar there. At the moment, all I’m able to do is put the URL in a frame, but it looks clunky as it shows the app drawer as well as the header (see below). Is there a way just to have the graphs shown?

While on the topic of My Solar and the like, is there any way to view the graphing as ‘Day so far’? As in, from midnight until current time of day?

I think the left menu is showing because you are logged in, perhaps in another tab of the the same browser?

Also if you use the &embed=1 parameter in the url used by HABpanel to fetch the app’s webpage the navbar should be hidden eg

https://server.com/app/view?name=MySolar&apikey=510xyzc93df6e123194xx3513999cc3f&embed=1

When testing/debugging stuff like this it is often handy to have a second “clean” browser instance, that may mean opening a different 2nd browser altogether or just incognito mode should work.

…oh and regarding

Not “out of the box”. The way apps work is different to the graphs, multigraphs and visualisations in emoncms, they cannot be saved with a particular interval span or start point, that would require coding in as a feature, either as an expansion of the existing app or as a separate app, there are no settings you can alter and there are no url parameters you can edit, the apps are javascript so a button would need pressing if it isn’t the hardcoded default page layout you want to view, much like the “show balance” or “view history” links, you cannot display those directly.

Thanks Paul, that embed code worked perfectly. Looks very pretty now.