HTML Script
HTML Script:
_______________________________________________
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>HTML Script</title>
<style>
h1{
background-color: black;
color: green;
border: 6px solid green;
font-size: 100px;
}
button{
background-color: black;
color: green;
border: 6px solid green;
border-radius: 20px;
font-size: 50px;
padding: 25px;
}
button:hover{
background-color: white;
color: black;
border-color:black;
transition: 0.5s;
}
</style>
</head>
<body>
<!--
getElementById() - method of the
"document" interface returns an "Element"
object representing the element whose
"id" property matches the specified string.
innerHTML - sets the HTML markup contained
within the element.
-->
<center>
<h1 id="change">Text</h1>
<button onclick="comm()">Change</button>
</center>
<script>
function comm(){
document.getElementById("change").innerHTML = "Dark Hers";
}
</script>
</body>
</html>
_____________________________________________
Dark Hers
YouTube
https://instagram.com/darkhers
https://www.facebook.com/darkhers
TikTok
https://www.tiktok.com/@darkhers
https://www.pinterest.co.uk/darkhers
Comments
Post a Comment