+ 1
var myVar1=document.getELementById"firstId ".innerHTML="say Hi", myVar2=document.getELementById"secId".innerHTML=" say how are
urgent plz help
3 Answers
+ 5
<p id="fId"></p>
<script>
document.getElementById("fId").innerHTML="Say hell0";
</script>
you need to know about {innerHTML}
+ 3
Wrong syntax
+ 1
document.getElementById("id").innetHTML;
instead of
document.getELementById"id".innerHTML;
and you should use = "say Hi" after that
var myVar1 = document.getElementById("firstid").innerHTML;
myVar1 = "say Hi";