Make it a real page · Jadikan halaman ini sebagai halaman nyata
This page needs a recent browser (with SharedArrayBuffer support). Please update Chrome, Edge, Firefox or Safari to the latest version. · Halaman ini memerlukan browser terbaru (dengan dukungan SharedArrayBuffer). Silakan perbarui Chrome, Edge, Firefox, atau Safari ke versi terbaru.
English
A real web page
- So far you wrote pieces of HTML. A full page wraps them in a frame.
- That frame is almost the same on every web page in the world.
- Let's meet it once — then it becomes a habit.
Bahasa Indonesia
Halaman web nyata
- Sejauh ini Anda telah menulis potongan-potongan HTML. Halaman lengkap membungkusnya dalam kerangka.
- Kerangka tersebut hampir sama di setiap halaman web di dunia.
- Mari kita kenalkan sekali — kemudian hal itu akan menjadi kebiasaan.
English
The four parts
<!DOCTYPE html>— the first line. It says: this is modern HTML.<html>— wraps the whole page.<head>— hidden information about the page (like its<title>).<body>— everything you see on the page.
Bahasa Indonesia
Empat bagian
<!DOCTYPE html>— baris pertama. Ia menyatakan: ini adalah HTML modern.<html>— membungkus seluruh halaman.<head>— informasi tersembunyi tentang halaman (seperti<title>-nya).<body>— segala sesuatu yang Anda lihat di halaman.
Explore · Jelajahi
The page skeleton as a tree · Rangka halaman sebagai pohon
Every page is a tree: <html> holds <head> (setup) and <body> (what you see). · Setiap halaman adalah pohon: <html> menampung <head> (pengaturan) dan <body> (apa yang Anda lihat).
<!DOCTYPE html>
<html>
<head>
<title>My first page</title>
</head>
<body>
<h1>Hello!</h1>
<p>This is a real web page.</p>
</body>
</html>
English
The title shows in the tab
- The
<title>does not appear on the page itself. - It is the name shown on the browser tab and in search results.
- Every page should have one.
Bahasa Indonesia
Judul muncul di tab
<title>tidak muncul di halaman itu sendiri.- Ini adalah nama yang ditampilkan pada tab browser dan dalam hasil pencarian.
- Setiap halaman harus memilikinya.
English
Common mistakes
- A page needs
<html>, a<head>and a<body>. - The tab title comes from
<title>inside<head>.
Bahasa Indonesia
Kesalahan umum
- Sebuah halaman memerlukan
<html>, sebuah<head>, dan sebuah<body>. - Judul tab berasal dari
<title>di dalam<head>.
English
Now you try
- Notice how
<head>and<body>sit inside<html>. - Add a title, then give a page its doctype line.
Bahasa Indonesia
Sekarang Anda coba
- Perhatikan bagaimana
<head>dan<body>berada di dalam<html>. - Tambahkan judul, lalu berikan baris doctype pada halaman.
Give the page a title. Add <title>My Page</title> inside the <head>. · Berikan judul pada halaman. Tambahkan <title>My Page</title> di dalam <head>.
Start this page properly. Add <!DOCTYPE html> as the very first line. · Mulai halaman ini dengan benar. Tambahkan <!DOCTYPE html> sebagai baris pertama.