🔌

Embedding a graph with tooltips into any web-site - simple mode & iframe

GET - /v1/users/<username>/graphs/<graphID>.html supports mode option (API document) . For example, if you access to /v1/users/<username>/graphs/<graphID>.html?mode=simple by using web-browser, so you can see like below.
This is what looks like when access to a certain graph with ?mode=simple .
This is what looks like when access to a certain graph with ?mode=simple .
What is the difference between this and GET - /v1/users/<username>/graphs/<graphID> ? The answer is that graph with ?mode=simple supports tooltips.
You can see the tooltips when you mouse over the pixels of the graph.
You can see the tooltips when you mouse over the pixels of the graph.
So, what is the purpose of this GET - /v1/users/<username>/graphs/<graphID>.html?mode=simple ? The answer is to use this when you want to embed the graph into any website with tooltips available.
To embed this graph into any website, use an iframe . The example is below:
HTML
To take advantage of this technique, the website you are embedding the graph into must support iframe . But you can easily embed Pixela's graph into any website.

Related