Style properties in HTML

The Style attribute specifies the style for the HTML element.

To define the style for the element in HTML, we use the style attribute, which has the following structure.

 
  1. dactinh is the property (property) of CSS
  2. giri is the value of CSS

See also: How to use CSS to style HTML pages

Background color in HTML

The background-color is used to define the background color for elements in HTML. This is an example of setting a blue background color for the page.

y style='background-color:powderblue;'> y style = 'background-color: powderblue;'>

Quản trị mạng Network administrator


Network administrator

 

Text color in HTML

The color feature is used to define the font color for elements in HTML.

n học HTML


Paragraph h

 Read the HTML text color. 

Font in HTML

The font-family is used to define the font used for HTML elements.

Learn HTML trên Quản trị mạng.


Study HT

 ML on Network Administrator. 

Font size in HTML

The font-size is used to define the font size for HTML elements.

Học HTML trên Quản trị mạng.


They

 c font size in HTML on Network Administrator. 

Align text in HTML

The text-align is used to align text for elements in HTML.

Văn bản nằm giữa trang. Text is in the middle of the page.


Text is in the middle of the page.

Picture 1 of Style properties in HTML

Show all the above code on Chrome browser

Last lesson: Text in HTML

The following article: Format text in HTML

Update 25 May 2019
Category

System

Mac OS X

Hardware

Game

Tech info

Technology

Science

Life

Application

Electric

Program

Mobile