Professional Documents
Culture Documents
HTML of Expanding Widget
HTML of Expanding Widget
DOCTYPE html>
<html lang=”en”>
<head>
<meta charset=”UTF-8”>
<title>Expanding Widget</title>
<style>
.expander {
Margin-bottom: 10px;
Cursor: pointer;
Color: blue;
Text-decoration: underline;
.details {
Display: none;
Margin-left: 20px;
</style>
<script>
Function toggleDetails(id) {
Details.style.display = “block”;
} else {
Details.style.display = “none”;
</script>
</head>
<body>
<h3>Parts of a Computer</h3>
<ul>
<li>CPU</li>
<li>Motherboard</li>
<li>RAM</li>
<li>GPU</li>
<li>PSU</li>
<li>Storage</li>
<li>Case</li>
</ul>
</div>
<h3>Fruits</h3>
<ul>
<li>Apple</li>
<li>Orange</li>
<li>Mango</li>
<li>Avocado</li>
<li>Strawberry</li>
</ul>
</div>
</body>
</html>