
Web_FE_BASIC_SS34
Authored by haibt@rikkei.edu.vn rikkei
Information Technology (IT)
University
Used 30+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
16 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Mục đích chính của DOM trong JavaScript là gì?
A. Tạo và quản lý cơ sở dữ liệu
B. Tương tác và thay đổi nội dung, cấu trúc và kiểu của tài liệu HTML hoặc XML
C. Thực hiện các phép toán số học
D. Tạo và quản lý các lớp học
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
DOM có thể làm gì với các phần tử trên trang web?
A. Chỉ đọc nội dung
B. Chỉ xóa nội dung
C. Thay đổi nội dung, cấu trúc và kiểu
D. Không thể làm gì với các phần tử
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cách truy xuất tất cả các phần tử với class cụ thể trong DOM là gì?
A. document.getElementByClass('class');
B. document.querySelectorAll('.class');
C. document.getElementsByClassName('class');
D. document.querySelector('.class');
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Phương thức nào sau đây trả về một phần tử duy nhất bằng ID?
A. document.querySelector('#id');
B. document.getElementsById('id');
C. document.getElementById('id');
D. document.querySelectorAll('#id');
5.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Làm thế nào để lấy nội dung HTML của một phần tử với ID myElement?
A. document.getElementById('myElement').innerHTML;
B. document.getElementById('myElement').textContent;
C. document.getElementById('myElement').value;
D. document.getElementById('myElement').innerText;
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Phương thức nào sau đây trả về tất cả các phần tử với tên thẻ p?
A. document.querySelector('p');
B. document.getElementsByTagName('p');
C. document.querySelectorAll('p');
D. document.getElementById('p');
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cách thêm một class vào phần tử với ID example là gì?
A. document.getElementById('example').className = 'newClass';
B. document.getElementById('example').classList.add('newClass');
C. document.getElementById('example').addClass('newClass');
D. document.getElementById('example').class = 'newClass';
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?