reading-notes

Duckett HTML book Chapter 5 : Images

There are many reasons why you might want to add an image to a web page: you might want to include a logo, photograph, illustration, diagram, or chart.

Adding Images

adding img

To add an image into the page you need to use an < img > element. This is an empty element (which means there is no closing tag). It must carry the following two attributes:

You will also often see an < img > element use two other attributes that specify its size:

height

This specifies the height of the image in pixels.

width

This specifies the width of the image in pixels.

Three Rules for Creating Images:

  1. Save images in the right format.
  2. Save images at the right size.
  3. Use the correct resolution.

Duckett HTML book Chapter 11 : Color

rgb values:

RGB (red, green, and blue) refers to a system for representing the colors to be used on a computer display. Red, green, and blue can be combined in various proportions to obtain any color in the visible spectrum. Levels of R, G, and B can each range from 0 to 100 percent of full intensity. Each level is represented by the range of decimal numbers from 0 to 255 (256 levels for each color).

rgb

hex codes:

Hex codes are a hexadecimal format for identifying colors. This is a system used in HTML, CSS and SVG. Each hex code refers to a very specific color, which allows for two designers or a designer and developer to be on the same page about what exact light blue (or any other color) they are referring to. They are always a six-digit code, which contains three pieces of information:

  1. The first two digits provide information about the amount of Red in a color
  2. The second two digits provide information about the amount of Green
  3. The last two digits provide information about the amount of Blue.

color names

There are 147 predefined color names that are recognized by browsers.

Opacity

opacity

HSL Colors

saturation


Duckett HTML book Chapter 12 : Text


JPEG vs PNG vs GIF