Video

Here you will find all posts tagged 'video'.

Web Development Tutorial Part 4 – Even More HTML

Posted September 18th, 2014 by

So having completed both Part 1 and Part 2 as well as Part 3 of this series of web development tutorials, we can now move on to discuss even more HTML elements. In the next part of this series, we’ll look at CSS, and finally make our webpages pretty.

Embedding Content

Images

The ‘Image’ element <img> allows us to embed images into our webpage. The image source is specified in the same way a link ‘href’ is, but the ‘src’ attribute is used instead:

<img src="image.png" alt="Non visual browsers see this">

The ‘alt’ tag specifies what to show if the image fails to load or cannot be shown. Note that the <img> tag is a void tag, and does not need closing. The images must be in a format readable by the browser, for example PNG, GIF or JPG.

Videos

The ‘Video’ element <video> allows us to embed videos into our webpage. This element acts similarly to the ‘Image’ element, and also has a ‘src’ attribute:

<video src="video.mp4">
    Your browser does not support &lt;video&gt;.
</video>

The ‘alt’ text is simply contained within the element, and will display on browsers that don’t support the element. Embedded videos must encoded in a way that the browser can understand, for example H.264.

(more…)

Comments: none yet | Filed under: tutorials | Tagged: , , , , , ,