Câu 16.
Đoạn mã HTML nào sau đây phù hợp để tạo một phần tử cho phép nhập mật khẩu trong một biểu mẫu đăng nhập?
- A.
<input type="text" name="password"> - B.Đáp án
<input type="password" name="password"> - C.
<textarea name="password"></textarea> - D.
<textarea type="password"></textarea>
Lời giải
Thẻ <input type="password"> tạo ô nhập một dòng mà các kí tự gõ vào được che đi, phù hợp để nhập mật khẩu. type="text" hiện rõ kí tự; <textarea> là vùng nhập nhiều dòng, không có kiểu password. Chọn B.