HTML also contains elements for adding images to your website.
The formats most used for the images added in a HTML page are GIF and JPEG (JPG ; JPE), the advantage of GIF images is that are small in size (in bytes), having a maximum of 256 colors.
Other format types that can be used are:

Adding a image in a webpage

To add an image in a HTML document you must use the element <img> ... </img> together with the following attributes:

In the following example you can see how you can include an image in your web page and how to use these attributes:
<html>
<head>
<title>The title</title>
</head>
<body>
<img src="image.jpg" alt="here you can add any text" align="top" width="100" height="120" border="4" hspace="10" vspace="7"></img>
</body>
</html>
- The web page will appear like this:
you can add any text

Try more examples by yourself, using other attributes and values.

Daily Test with Code Example

HTML
CSS
JavaScript
PHP-MySQL
Which attribute is used in <a> tag for the address of the link?
src href rel
<a href="http://coursesweb.net/" title="CoursesWeb.net">CoursesWeb.net</a>
Which CSS property sets the type of the text font?
font-family text-decoration font-size
h2 {
  font-family:"Calibri",sans-serif;
}
What instruction selects all the <div> tags with class="cls"?
querySelector("div.cls") getElementsByTagName("div") querySelectorAll("div.cls")
var elm_list = document.querySelectorAll("div.cls");
var nr_elms = elm_list.length;       // number of selected items
alert(nr_elms);
Indicate the function that can be used to get the sum of values in an array.
array_sum() array_diff() array_shift()
$arr = array(1, 2, 3, 4);
$arr_sum = array_sum($arr);
echo $arr_sum;       // 10
Adding images

Last accessed pages

  1. Mahjong Games (8009)
  2. Emma Christmas Tree (43)
  3. Makeup Game (37)
  4. jQuery Ajax - load() method (7620)
  5. Sport Games (2108)

Top accessed pages

  1. Courses Web: PHP-MySQL JavaScript Ajax HTML CSS Flash-AS3 (47990)
  2. Read Excel file data in PHP - PhpExcelReader (36111)
  3. PHP-MySQL free course, online tutorials PHP MySQL code (35689)
  4. Get Attribute (ID, Class, Name, Title, Src) with jQuery (32182)
  5. PHP PDO - exec (INSERT, UPDATE, DELETE) MySQL (29461)