How to change the width of widgets? - gauge, lamp, numerical display
8 views (last 30 days)
Show older comments
Hello everyone,
first of all thank you for the amazing service the Thingspeak platform is. The possibilities are limitless!
For my project I´d like to display the values in different ways on a separate website, embedding them. I am using all sorts of displays like graphing multiple lines, gauges, lamps and also simple numerical value display.
The problem I am currently unable to solve is - how to change the width and heigth of these "native" plugins?
I know one can change the width and heigth of Chart https://community.thingspeak.com/forum/thingspeak-api/changing-iframe-height-and-width/ but I cannot find a way to do the same for the plugins.
Is there a way?
My public dashboard: https://thingspeak.com/channels/929488
the plugins are simple too large for my custom display.
0 Comments
Accepted Answer
Vinod
on 16 Jan 2020
Edited: Vinod
on 16 Jan 2020
If you are familiar with HTML and CSS, you can use CSS to resize the widget. For example, create a new HTML file called example.html with this text:
<html>
<style>
#frame { width: 400px; height: 300px; border: none}
#frame {
-ms-zoom: 0.75;
-moz-transform: scale(0.75);
-moz-transform-origin: 0px 0;
-o-transform: scale(0.75);
-o-transform-origin: 0 0;
-webkit-transform: scale(0.75);
-webkit-transform-origin: 0 0;
}
</style>
<div id="wrap">
<iframe id="frame" src="https://thingspeak.com/channels/929488/widgets/126606"></iframe>
</div>
</html>
Now, open that in your browser and compare that to just opening the widget
1 Comment
Mi He2
on 27 Mar 2021
but this does not solve the problem of free space, because this object will occupy the original size, it will only be reduced(zoomed). At least that's how it shows me.
More Answers (0)
Communities
More Answers in the ThingSpeak Community
See Also
Categories
Find more on Read Data from Channel in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!