-
Notifications
You must be signed in to change notification settings - Fork 0
/
index2.html
63 lines (57 loc) · 1.67 KB
/
index2.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>DOM</title>
<style>
.bg-black{
background-color: black;
color: white;
}
body{
background-color: black;
}
</style>
</head>
<body>
<div class="bg-black">
<h1 id="title">hello world i m here <span style="display: none;">yes you heared that right</span></h1>
<h2>Lorem ipsum dolor sit amet consectetur, adipisicing elit.</h2>
<h3>Lorem ipsum dolor sit amet, consectetur adipisicing.</h3>
<p>Lorem ipsum dolor sit amet.</p>
<ul>
<li>one</li>
<li>two</li>
<li>three</li>
<li>four</li>
</ul>
<input type="submit">
<div class="day">monday</div>
<div class="day">tuesday</div>
<div class="day">wednesday</div>
<div class="day">thursday</div>
</div>
<script>
const parent=document.querySelector(".parent")
console.log(parent);
</script>
</body>
<script>
function addlanguage(langname){
const li= document.createElement("li");
li.innerHTML=`$(langname)`
document.querySelector(`.language`)
appendchild(li)
}
addlanguage("python")
addlanguage("c++")
function addoptilanguage(langname){
const li = consdocument.createElement('li');
// const addtext = document.createElement()
li.appendchild(document.createTextNode(langname))
document.querySelector('.language').appendchild(li)
}
addoptilanguage('log')
</script>
</html>