HTML5 New Elements

New Elements in HTML5 Below is a list of the new HTML5 elements, and a description of what they are used for. New Semantic/Structural Elements HTML5 offers new elements for better document structure: Tag Description <article> Defines an article <aside> Defines content aside from the page content <audio> Defines sound content <bdi> Isolates a part […]

HTML <wbr> Tag

Example A text with word break opportunities: <p> To learn AJAX, you must be familiar with the XML<wbr>Http<wbr>Request Object. </p> Try it Yourself » Definition and Usage The <wbr> (Word Break Opportunity) tag specifies where in a text it would be ok to add a line-break. Tip: When a word is too long, or you are […]

HTML <canvas> Tag

Example Draw a red square, on the fly, and show it inside the <canvas> element: <canvas id=”myCanvas”></canvas> <script> var canvas = document.getElementById(“myCanvas”); var ctx = canvas.getContext(“2d”); ctx.fillStyle = “#FF0000”; ctx.fillRect(0, 0, 80, 80); </script> Try it Yourself » Definition and Usage The <canvas> tag is used to draw graphics, on the fly, via scripting (usually JavaScript). The <canvas> tag is only a container […]