-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathObject1.html
More file actions
27 lines (26 loc) · 832 Bytes
/
Copy pathObject1.html
File metadata and controls
27 lines (26 loc) · 832 Bytes
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Object1</title>
</head>
<body style="border: double; width: 50%";>
<div style="position: absolute; left: 370px;"><img style="width: 19%" src="mario.jpg"></div>
<script>
var FEDeveloper={
name: "Nike",
secondName:"Petrov",
sex: "male",
age: "88",
country: "Ukraine",
job: "developer"
};
var color=["azure", "blanchedalmond", "gainsboro", "yellow", "beige", "darkseagreen", "steelblue"];
for(var key in FEDeveloper) {
document.write("<div style='background-color:"+color[Math.round(Math.random()*(color.length))]+" ; width: 70%'>")
document.write("<p style='color: darkslategray; font-family: cursive; text-align: center;'>"+key + " = " + FEDeveloper[key]+"</p>");
document.write("</div>");
}
</script>
</body>
</html>