شرح لبعض وسوم لغة HTML او ال Tages الدرس 003

HTML Tags

HTML tags are keywords (tag names) surrounded by angle brackets:
<tagname>content</tagname>
  • HTML tags normally come in pairs like <p> and </p>
  • The first tag in a pair is the start tag, the second tag is the end tag
  • The end tag is written like the start tag, but with a slash before the tag name

The start tag is often called the opening tag. The end tag is often called the closing tag.

HTML Example

<!DOCTYPE html>
<html>
<head>
  <title>Page Title</title>
</head>

<body>
  <h1>My First Heading</h1>
  <p>My first paragraph.</p>
</body>

</html>


Web Browsers

The purpose of a web browser (Chrome, IE, Firefox, Safari) is to read HTML documents and display them.
The browser does not display the HTML tags, but uses them to determine how to display the document:

 

Example Explained

  1. The DOCTYPE declaration defines the document type to be HTML

  2. The text between <html> and </html> describes an HTML document
  3. The text between <head> and </head> provides information about the document
  4. The text between <title> and </title> provides a title for the document
  5. The text between <body> and </body> describes the visible page content
  6. The text between <h1> and </h1> describes a heading
  7. The text between <p> and </p> describes a paragraph

ويحدد الإعلان DOCTYPE نوع الوثيقة لتكون HTML
النص بين <HTML> و </ HTML> ويصف وثيقة HTML
النص بين <head> و </ head> يوفر معلومات حول المستند
النص بين <title> و </ title> يوفر عنوانا للوثيقة
النص بين <body> و </ body> يصف محتوى الصفحة مرئية
النص بين <H1> و </ H1ويصف عنوان
النص بين <P> و </ P> ويصف فقرة

HTML Page Structure

Only the <body> area 

The <!DOCTYPE> Declaration

The <!DOCTYPE> declaration helps the browser to display a web page correctly.
There are different document types on the web.
To display a document correctly, the browser must know both type and version.
The doctype declaration is not case sensitive. All cases are acceptable:(the white area) is displayed by the browser.<!DOCTYPE html>

<!DOCTYPE HTML>

<!doctype html>

<!Doctype Html>

Common Declarations

HTML5

<!DOCTYPE html>

HTML 4.01

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://ift.tt/kTyqzh">

XHTML 1.0

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://ift.tt/kkyg93">


تعليقات

المشاركات الشائعة