ข้อมูลอ้างอิง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 <input> d irname Attribute

❮ แท็ก HTML <input>

ตัวอย่าง

แบบฟอร์ม HTML ที่จะส่งทิศทางข้อความของฟิลด์:

<form action="/action_page.php">
  <label for="fname">First name:</label>
  <input type="text" id="fname" name="fname" dirname="fname.dir">
  <input type="submit" value="Submit">
</form>

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

คุณลักษณะdirnameช่วยให้ส่งทิศทางข้อความของช่องใส่

ค่าdirnameของแอตทริบิวต์จะเป็นชื่อของช่องป้อนข้อมูลเสมอ ตามด้วย ".dir"


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

ตัวเลขในตารางระบุเบราว์เซอร์รุ่นแรกที่สนับสนุนแอตทริบิวต์อย่างเต็มที่

Attribute
dirname Yes 79.0 Not supported Yes Yes

ไวยากรณ์

<input name="myname" dirname="myname.dir">

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

Value Description
name.dir Specifies that the text direction of the input field will be submitted.

❮ แท็ก HTML <input>