ข้อมูลอ้างอิงHTML

HTML โดยตัวอักษร HTML ตามหมวดหมู่ รองรับ HTML Browser แอตทริบิวต์ HTML HTML Global Attributes เหตุการณ์ HTML HTML สี HTML Canvas HTML เสียง/วิดีโอ ชุดอักขระ HTML HTML Doctypes การเข้ารหัส URL HTML รหัสภาษา HTML รหัสประเทศ HTML ข้อความ HTTP วิธี HTTP ตัวแปลง PX เป็น EM แป้นพิมพ์ลัด


HTML <base> แอตทริบิวต์เป้าหมาย

❮ แท็ก HTML <base>

ตัวอย่าง

ระบุเป้าหมายเริ่มต้นสำหรับไฮเปอร์ลิงก์และฟอร์มทั้งหมดบนหน้า:

<head>
  <base target="_blank">
</head>

ความหมายและการใช้งาน

แอตทริบิวต์targetระบุเป้าหมายเริ่มต้นสำหรับไฮเปอร์ลิงก์และแบบฟอร์มทั้งหมดในหน้า

แอตทริบิวต์นี้สามารถแทนที่ได้โดยใช้ targetแอตทริบิวต์สำหรับแต่ละไฮเปอร์ลิงก์/ฟอร์ม


รองรับเบราว์เซอร์

Attribute
target Yes Yes Yes Yes Yes

ไวยากรณ์

<base target="_blank|_self|_parent|_top">

ค่าแอตทริบิวต์

Value Description
_blank Opens the link in a new window or tab
_self Default. Opens the link in the same frame as it was clicked
_parent Opens the link in the parent frame
_top Opens the link in the full body of the window

❮ แท็ก HTML <base>