HTML Tab
Last updated
Last updated
HTML (Hyper Text Markup Language) is the standard markup language with which any web page is structured. By using HTML elements, the user can tell the browser where and how to display content.
<title> Page Title </title>
: This element tells the browser to display the "Page Title" message as the tittle for the web page.
<h1> This is a h1 header </h1>
: This element tells the browser to display the "This is a h1 header" message as an H1 header wherever it is placed in the HTML file.
<p> My first paragraph </p>
: This element tells the browser to display the "My first paragraph" message as a paragraph wherever it is placed in the HTML file.
In every HTML file the following structure is mandatory:
When using HTML elements on the HTML Canvas widget, using the following tags is optional:
<html></html>
<head></head>
<body></body>
This means that all the code that is placed in the HTML code editor tab will be interpreted as if it were inside an HTML body element on the widget:
<html>
<head>
</head>
<body>
<h1> This is a h1 header </h1>
<p> This is a paragraph </p>
<p> This is another paragraph </p>
</body>
</html>
<h1> This is a h1 header </h1>
<p> This is a paragraph </p>
<p> This is another paragraph </p>
Suppose the following web content has to be displayed:
This can be achieved with the following HTML code:
In order to achieve this same result on the HTML Canvas, the following code can be used on the HTML tab of the code editor:
The resulting HTML Canvas Widget is shown below on a dasboard: