0
Hello guys it alaways says that there is no method for #<html document>. 'getElementById' what should I do?
2 Answers
0
document.getElementById("tag_id")
You have to say what you want to do.
Type:
document.getElementById('tag_id').value //Capture the value
0
this is the program guys
<!DOCTYPE html>
<html>
<head></head>
<body>
<div class="hello">
This doesn't work!!!!!
</div>
</body>
<script type="text/javascript">
var a=
document.getElementsByClassName("hello");
a.style.color="red";
</script>
</html>