Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

Materi HTML:

Link
Here is where your presentation begins
02
Links
Syntax HTML Links
<a href =”url ”>Link text</a>
Value dari target atribut di HTML Links

<a href =”url ” target=”...”>Link text</a>

Nama Atribut Fungsi Atribut

_self Default. Opens the document in the same window/tab as it was clicked

_blank Opens the document in a new window or tab

_parent Opens the document in a new window or tab

_top Opens the document in the full body of the window


Jenis link URL

Absolute Relatives
Jenis link URL yang diambil Jenis link URL yang diambil
dari website yang sudah ada langsung dari folder yang sama
dengan website

<a href = ”www.smapetrus.net ”> Website Sekolah </a>


<a href= ”utama/kalender.html”> Kalender Akademik </a>
Fungsi Penggunaan Link Lainnya
HTML LINKS Contoh Link HTML

Link to an Email Address <a href="mailto:someone@example.com">Send email</a>

Use an Image as a Link <img src="smiley.gif" alt="HTML tutorial" style="width:42px;">

Button as a Link <button onclick="document.location='default.asp'"> HTML Tutorial</button>

Link Titles <a href="www.smapetrus.net" title="SMA Santu Petrus">WEBSITE RESMI</a>

Bagian ID → <h2 id="C4">Chapter 4</h2>


Link Bookmark
Bagian Link → <a href="#C4">Jump to Chapter 4</a>

You might also like