Course / دورة
HTMLإتش تي إم إل
Build the structure of a web page
ابنِ هيكل صفحة الويب
beginner 34 lessons 9 chapters 16 hours
0 / 34 lessons completed / دروس مكتملة
What you will be able to do / ماذا ستستطيع أن تفعل
- Write a complete page from an empty file تكتب صفحة كاملة من ملف فارغ
- Choose the element that means what you intend, not just what looks right تختار العنصر الذي يحمل المعنى المقصود لا الشكل فقط
- Build a form that collects and checks what a user types تبني نموذجًا يجمع ما يكتبه المستخدم ويتحقق منه
- Make a page usable by someone who cannot see it تجعل الصفحة قابلة للاستخدام لمن لا يراها
1 First pageأول صفحة 5
-
1
What is HTML & how the web works / ما هي HTML وكيف يعمل الويب
A web page is a text file. HTML is the language it is written in, and the browser is what turns it into a page.
صفحة الويب ملف نصي، ولغته هي HTML، والمتصفح هو الذي يحوّله إلى صفحة.
-
2
Your first .html file / أول ملف .html تكتبه
Everything starts with one plain text file, saved with a
.htmlextension, opened in a browser. This lesson walks through doing exactly that, one careful step at a time.كل شيء يبدأ بملف نصي عادي واحد، محفوظ بامتداد
.html، ومفتوح في متصفح. هذا الدرس يشرح كيف تفعل ذلك بالضبط، خطوة خطوة بعناية. -
3
The page skeleton / هيكل صفحة HTML
Every real HTML page has the same four-part shape: a doctype,
<html>,<head>, and<body>. This lesson shows what each part is for.لكل صفحة HTML حقيقية نفس الشكل المكوَّن من أربعة أجزاء: doctype، و
<html>، و<head>، و<body>. يشرح هذا الدرس وظيفة كل جزء منها. -
4
Looking inside a page / النظر داخل الصفحة
Every browser has a set of developer tools built in. They let you see the page as the browser understands it, and change it live — the fastest way to learn, and the fastest way to fix.
في كل متصفح أدوات مطوّرين مدمجة. تتيح لك رؤية الصفحة كما يفهمها المتصفح، وتعديلها مباشرة — وهي أسرع طريقة للتعلّم، وأسرع طريقة للإصلاح.
-
5
Elements, tags & attributes / العناصر والوسوم والسمات
An element is an opening tag, its content and its closing tag — except for void elements, which have no closing tag at all. Attributes add extra information inside an opening tag, written
name="value".العنصر هو وسم فتح ومحتوى ووسم إغلاق — إلا العناصر الفارغة، التي لا وسم إغلاق لها أصلًا. والسمات تضيف معلومات إضافية داخل وسم الفتح، وتُكتب
name="value".
2 Textالنصوص 6
-
6
Headings h1–h6 / العناوين h1–h6
HTML gives you six heading levels,
<h1>down to<h6>. The number is a rank, not a size.تعطيك HTML ستة مستويات للعناوين، من
<h1>إلى<h6>، والرقم يدل على الأهمية لا على الحجم. -
7
Paragraphs / الفقرات
The
<p>tag marks one paragraph, one idea. The browser collapses every space and line break inside it into a single space, and adds its own spacing above and below.الوسم
<p>يُعرِّف فقرة واحدة، فكرة واحدة. والمتصفح يدمج كل مسافة وسطر جديد داخلها في مسافة واحدة، ويضيف تباعده الخاص فوقها وتحتها. -
8
Breaks and rules / كسر السطر والفاصل والنص المنسّق مسبقًا
Three tags for shaping text precisely:
<br>forces a line break,<hr>marks a break between topics, and<pre>keeps your spacing exactly as you typed it.ثلاثة وسوم لتشكيل النص بدقة:
<br>يفرض كسر سطر، و<hr>يفصل بين موضوعين، و<pre>يحافظ على تباعدك كما كتبته تمامًا. -
9
Text formatting: meaning over looks / تنسيق النص: المعنى لا الشكل
Seven tags for text that carries meaning, not just a look —
<strong>marks real importance and<em>marks real emphasis, and appearance is only ever a side effect.سبعة وسوم لنص يحمل معنى، لا مجرد شكل —
<strong>تعني أهمية حقيقية و<em>تعني تشديدًا حقيقيًا، والمظهر ليس إلا أثرًا جانبيًا. -
10
Quotations and citing sources / الاقتباس وذكر المصدر
Four tags for quoting someone else's exact words:
<blockquote>for a quotation that stands on its own,<q>for one inside a sentence,<cite>to name the source, and<abbr>to spell out an abbreviation on hover.أربعة وسوم لاقتباس كلام شخص آخر كما قاله بالضبط:
<blockquote>لاقتباس قائم بذاته، و<q>لاقتباس داخل جملة، و<cite>لذكر المصدر، و<abbr>لشرح اختصار عند المرور عليه بالمؤشر. -
11
Comments / التعليقات
A comment, written
<!-- like this -->, is a note the browser skips completely — for notes to yourself and for hiding a piece of code while you test.التعليق، ويُكتب
<!-- هكذا -->، ملاحظة يتجاوزها المتصفح تمامًا — لتدوين ملاحظات لنفسك، ولإخفاء قطعة كود مؤقتًا أثناء الاختبار.
3 Links and imagesالروابط والصور 4
-
12
Links: absolute and relative paths / الروابط: المسار المطلق والنسبي
The
<a>tag turns text into a link. Itshrefattribute is the destination — another site, a file beside yours, an email address, or a phone number.الوسم
<a>يحوّل النص إلى رابط، وسمتهhrefهي الوجهة: موقع آخر، أو ملف بجانب صفحتك، أو بريد إلكتروني، أو رقم هاتف. -
13
In-page navigation with anchors / التنقل داخل الصفحة
Give any element an
idand you can link straight to it with#— the browser jumps to that spot on the same page instead of loading a new one.أعطِ أي عنصر سمة
idوستستطيع الربط إليه مباشرة بـ#— فيقفز المتصفح إلى تلك النقطة في الصفحة نفسها بدل تحميل صفحة جديدة. -
14
Images and captions / الصور والتعليقات التوضيحية
The
<img>tag shows a picture on the page. It needs asrcto know which file, and analtto say what is in it — for the visitor who cannot see it.الوسم
<img>يعرض صورة في الصفحة. يحتاجsrcليعرف أي ملف، وaltليقول ما فيها — من أجل الزائر الذي لا يستطيع رؤيتها. -
15
Responsive images / الصور المتجاوبة
One image file cannot suit both a phone and a wide screen.
srcsetoffers the browser a choice of sizes,<picture>lets you swap the image entirely, andloading="lazy"keeps the ones further down from slowing the page.ملف صورة واحد لا يناسب الهاتف والشاشة العريضة معًا. تعرض
srcsetعلى المتصفح خيارات من الأحجام، ويتيح<picture>استبدال الصورة كليًا، ويمنعloading="lazy"الصور البعيدة من إبطاء الصفحة.
4 Lists and tablesالقوائم والجداول 4
-
16
Ordered and unordered lists / القوائم المرتبة وغير المرتبة
Use
<ul>for a list where order does not matter, and<ol>for one where it does — every item, either way, goes inside its own<li>.استخدم
<ul>لقائمة لا يهم فيها الترتيب، و<ol>لقائمة يهم فيها الترتيب — وفي الحالتين كل عنصر يوضع داخل<li>خاص به. -
17
Description lists / قوائم الوصف
Use
<dl>when you have a set of terms and their meanings — each<dt>is a term, each<dd>is what it means.استخدم
<dl>عندما يكون لديك مجموعة من المصطلحات ومعانيها — كل<dt>مصطلح، وكل<dd>معناه. -
18
Tables: the basics / الجداول: الأساسيات
A table is a grid of rows and cells for data that truly has rows and columns — not a tool for arranging the page.
الجدول شبكة من الصفوف والخلايا للبيانات التي فيها فعلًا صفوف وأعمدة — وليس أداة لترتيب الصفحة.
-
19
Advanced tables / الجداول المتقدمة
Group a table into row sections, make one cell span several rows or columns, and give the whole table a caption a screen reader announces first.
جمّع صفوف الجدول في أقسام، اجعل خلية واحدة تمتد عبر عدة صفوف أو أعمدة، وأعطِ الجدول كله عنوانًا توضيحيًا يعلنه قارئ الشاشة أولًا.
5 Structuring a pageهيكلة الصفحة 3
-
20
div and span / الوسمان div و span
<div>and<span>are containers with no meaning of their own —<div>for a block,<span>for a piece of inline text — that exist purely so CSS can style or position them later.<div>و<span>حاويتان بلا معنى خاص بهما —<div>لكتلة، و<span>لقطعة نص مضمّنة — وجودهما فقط ليتيحا لـ CSS تنسيقهما أو تحديد موضعهما لاحقًا. -
21
Data attributes & inline SVG / سمات البيانات وSVG المضمّن
Two things every real page uses:
data-*attributes for attaching your own information to an element, and inline<svg>for icons that stay sharp and take their colour from the text around them.شيئان تستخدمهما كل صفحة حقيقية: سمات
data-*لإرفاق معلوماتك الخاصة بعنصر، و<svg>المضمّن للأيقونات التي تبقى حادة وتأخذ لونها من النص حولها. -
22
Semantic layout / التخطيط الدلالي
Elements like
<header>,<nav>,<main>and<footer>say what a region of the page actually is, not just how to group it — which is what makes a page usable by screen readers and search engines, not only by eyes.عناصر مثل
<header>و<nav>و<main>و<footer>تقول ما هي منطقة الصفحة فعلًا، لا مجرد كيفية تجميعها — وهذا ما يجعل الصفحة قابلة للاستخدام بقارئات الشاشة ومحركات البحث، لا بالعين وحدها.
6 Formsالنماذج 5
-
23
Introduction to forms / مقدمة إلى النماذج
A form is how a page collects something from the visitor and sends it somewhere. You need four things:
<form>,action,method, and an input with a label.النموذج هو الطريقة التي تجمع بها الصفحة شيئًا من الزائر وترسله إلى مكان ما. وتحتاج فيه إلى أربعة أشياء:
<form>وactionوmethodوحقل إدخال له تسمية. -
24
Input types / أنواع حقل الإدخال
The
typeattribute changes what kind of box an<input>gives you — and, on a phone, which keyboard appears. It is a hint to the browser, not a guarantee.سمة
typeتُغيّر نوع الصندوق الذي يعطيك إياه<input>— وعلى الهاتف، تُغيّر لوحة المفاتيح التي تظهر. وهي تلميح للمتصفح لا ضمان. -
25
Checkboxes, radios and dropdowns / مربعات الاختيار والقوائم المنسدلة
Sometimes a visitor should pick from a fixed set instead of typing freely. Checkboxes let them choose several; radio buttons — tied together by a shared
name— let them choose exactly one;<select>gives a dropdown list; and<datalist>only suggests values while still letting them type anything.أحيانًا يجب أن يختار الزائر من مجموعة محددة بدل الكتابة الحرة. مربعات الاختيار تتيح له اختيار أكثر من واحد، وأزرار الاختيار — المرتبطة معًا بسمة
nameمشتركة — تتيح له اختيار واحد فقط، و<select>يعطي قائمة منسدلة، أما<datalist>فيقترح قيمًا فقط بينما يظل بإمكانه كتابة أي شيء. -
26
Longer text, buttons and field groups / النصوص الطويلة والأزرار وتجميع الحقول
This lesson covers
<textarea>for multi-line text, the three types a<button>can take, and<fieldset>/<legend>for grouping related fields together.يغطي هذا الدرس
<textarea>للنصوص متعددة الأسطر، والأنواع الثلاثة التي يقبلها<button>، و<fieldset>/<legend>لتجميع الحقول المرتبطة معًا. -
27
Validating form input / التحقق من صحة الإدخال
HTML can ask the browser to check a field before it submits —
required,pattern,minandmax. This is convenience, never security: the server must always check the data again.تستطيع HTML أن تطلب من المتصفح التحقق من الحقل قبل الإرسال — بـ
requiredوpatternوminوmax. وهذا للراحة فقط، وليس أمانًا: يجب أن يتحقق الخادم من البيانات مرة أخرى دائمًا.
7 The rest of the languageبقية اللغة 3
-
28
Entities & symbols / الكيانات والرموز
HTML reserves
<,>and&for its own syntax, so to show one of them as plain text you write a short code called an entity instead — plus a handful of others, like and©, for characters your keyboard cannot type.تحتفظ HTML بالحروف
<و>و&لصياغتها الخاصة، ولذلك تكتب لإظهار أي منها كنص عادي رمزًا قصيرًا يسمى كيانًا بدلًا من الحرف نفسه — إضافة إلى عدد آخر منها، مثل و©، لحروف لا تستطيع لوحة مفاتيحك كتابتها مباشرة. -
29
Audio, video and embedded pages / الصوت والفيديو والصفحات المضمّنة
<audio>plays a sound file,<video>plays a video with a set of built-in controls, and<iframe>embeds an entirely separate web page — a map, a video host, anything with a URL — inside yours.<audio>يشغّل ملف صوت، و<video>يشغّل فيديو بمجموعة أدوات تحكم جاهزة، و<iframe>يُضمّن صفحة ويب منفصلة تمامًا — خريطة، أو مضيف فيديو، أو أي شيء له رابط — داخل صفحتك. -
30
Accordions and dialogs, without JavaScript / الأقسام القابلة للطي والحوارات، بلا JavaScript
HTML has two interactive elements built in:
<details>opens and closes a section, and<dialog>is a real modal. Both come with keyboard support and screen reader support you would otherwise have to write yourself.في HTML عنصران تفاعليان مدمجان:
<details>يفتح قسمًا ويغلقه، و<dialog>نافذة حوار حقيقية. ويأتي كلاهما بدعم لوحة المفاتيح وقارئ الشاشة الذي كنت ستكتبه بنفسك لولاهما.
8 The head, and reaching everyoneالرأس وإتاحة الوصول 3
-
31
What goes in the head / داخل رأس الصفحة
The
<head>holds information about the page that never appears in the page itself: the character encoding, the mobile viewport, the search-engine description, and the tab icon.يحمل
<head>معلومات عن الصفحة لا تظهر داخلها أبدًا: ترميز الأحرف، والعرض على الجوال، والوصف الذي تراه محركات البحث، وأيقونة التبويب. -
32
Linking CSS and JS to your page / ربط CSS و JS بصفحتك
A page becomes real once you connect it to a stylesheet with
<link>and a script with<script>— two tags that pull in the files that make the page look good and do things.تصبح الصفحة حقيقية حين تربطها بملف تنسيق عبر
<link>وبملف سكربت عبر<script>— وسمان يجلبان الملفات التي تُجمّل الصفحة وتجعلها تفعل شيئًا. -
33
Accessibility basics / أساسيات إتاحة الوصول
Accessibility is not new syntax — it is using
alt,<label>, heading order and the rightlangthe way they were meant to be used, so a screen reader can read your page correctly.إتاحة الوصول ليست صيغة جديدة، بل استعمال
altو<label>وترتيب العناوين والسمةlangالصحيحة كما ينبغي، ليستطيع قارئ الشاشة قراءة صفحتك بشكل صحيح.