","upvoteCount":5},{"@type":"Answer","text":"var arr = document.getElementsByTagName(\"p\");\r\nfor(var x=0; x\r\nvar d = document.\r\n getElementById (\"p2 \");\r\nd.style .color =\"red\";\r\n","upvoteCount":1},{"@type":"Answer","text":"fill in the blanks to alert a massage when the button is clicked. \r\n\r\nANSWER:- \r\n _msg() { alert(\"Hi!\"); } \r\n\r\nANSWER:- \r\n\r\nonclick \r\nfunction","upvoteCount":1},{"@type":"Answer","text":"document.\r\np\r\nx","upvoteCount":1},{"@type":"Answer","text":"","upvoteCount":0},{"@type":"Answer","text":"","upvoteCount":0},{"@type":"Answer","text":"var arr = document.getElementsByTagName(\"p\");\r\nfor(var x=0; x\r\nvar d = document.\r\n getElementById(\"p2\");\r\nd.style.color=\"red\";\r\n","upvoteCount":0},{"@type":"Answer","text":"darg and drop from the options below to change the color of the paragraph with id=\"p2\" to red.\r\n\r\nANSWER:- \r\n\r\n","upvoteCount":0},{"@type":"Answer","text":"Drag and drop from the options below to change the color of the paragraph with id=\"p2\" to red.\r\n\r\n","upvoteCount":0},{"@type":"Answer","text":"Fill in the blanks to change the content of the paragraphs with id=\"demo\" to \"Hi\" maintaining the HTML markup.\r\n\r\n$(function() {\r\n $(\"#demo\").html(\"Hi\");\r\n});","upvoteCount":0},{"@type":"Answer","text":"Dom & Events\r\nSelecting Elements\r\n\r\nFill in the blanks to select the element with id=\"text\" and change its content to \"Hi\".\r\n\r\n var ob = document.getElementById(\"text\");\r\n ob.innerHTML= \"Hi\";","upvoteCount":0},{"@type":"Answer","text":"Fill in the blanks to select all
elements, that are children of the element with \r\n\r\nid=\"demo\".\r\n$\r\n(\"#demo p\")","upvoteCount":0},{"@type":"Answer","text":"var arr = \r\ndocument\r\n.\r\n\r\n getElementsByTagName(\"\r\np\r\n\");\r\n\r\nfor(var x=0; x
+ 8
Discuss
Module 7 Quiz
1/6
Fill in the blanks to change the content of all paragraph tags of the page to "SoloLearn".
var arr =
<script>
var d = document.
getElementById ("p2 ");
d.style .color ="red";
</script>
25th Jun 2018, 11:53 AM
sapram charanteja
+ 1
fill in the blanks to alert a massage when the button is clicked.
ANSWER:-
<button onclick ="func()"> Click Here </button> _msg() { alert("Hi!"); } </script >
ANSWER:-
onclick
function
11th Jun 2020, 6:15 PM
Shailesh Kumar meena
+ 1
document.
p
x
8th Jan 2021, 8:24 AM
Vijayanathan Menakan
0
<script>
var d = document.
getElementById ("p2 ");
d.style .color ="red";
</script>
24th Mar 2018, 8:16 AM
Mahnoor Shahzad
0
<script>
var d = document.getElementById
("p2 ");
d.style.color ="red";
</script>
16th Sep 2019, 9:45 AM
ISINGIZWE GASANA Aline
0
var arr = document.getElementsByTagName("p");
for(var x=0; x<arr.length; x++){
arr[x].innerHTML="SoloLearn";
}
6th Nov 2019, 12:03 AM
Kimver Iman
0
var arr = document.getElementsByTagName("p");
for(var x=0; x<arr.length; x++){
arr[x].innerHTML="SoloLearn";
}
script>
var d = document.
getElementById("p2");
d.style.color="red";
</script>
29th Apr 2020, 3:53 PM
Druide LEKOGHO
0
darg and drop from the options below to change the color of the paragraph with id="p2" to red.
ANSWER:-
<script> var d = document.getElementById ("p2 "); d.style.color ="red"; </script>
11th Jun 2020, 5:59 PM
Shailesh Kumar meena
0
Drag and drop from the options below to change the color of the paragraph with id="p2" to red.
<script>
var d = document.
getElementById("p2");
d.style.color="red";
</script>
2nd Jul 2020, 7:48 PM
Rustamjon Kosimov
0
Fill in the blanks to change the content of the paragraphs with id="demo" to "<b>Hi</b>" maintaining the HTML markup.
$(function() {
$("#demo").html("<b>Hi</b>");
});
21st Nov 2020, 12:25 PM
Jason Chew
0
Dom & Events
Selecting Elements
Fill in the blanks to select the element with id="text" and change its content to "Hi".
var ob = document.getElementById("text");
ob.innerHTML= "Hi";
24th Nov 2020, 2:12 PM
Denise De Gomes Prego
0
Fill in the blanks to select all <p> elements, that are children of the element with
id="demo".
$
("#demo p")
8th Mar 2021, 5:49 PM
Mostafa Alafif
0
var arr =
document
.
getElementsByTagName("
p
");
for(var x=0; x<arr.length; x++)
{
arr[
x
].innerHTML="SoloLearn";
}
9th Aug 2021, 2:40 PM
Owethu Sotomela
0
document
p
x
11th Aug 2021, 3:51 PM
W.G.A.C.Nandasena
0
var arr = document.getElementsByTagName("p");
for(var x=0; x<arr.length; x++){
arr[x].innerHTML="SoloLearn";
}