+ 1

Do you need to specify an "Id" when you are trying to use the javascript document.getElementById("Id").innerHTML

Do you need to specify an "Id" when you are trying to use the javascript document.getElementById("Id").innerHTML is there no way? And also does the first word need to start with an uppercase like "document.getElementById("Id).innerHTML And "document.getelementbyid("Id).innerhtml"

3rd Jun 2019, 7:20 AM
Dprincebh
Dprincebh - avatar
2 Respuestas
+ 1
Camel Case is not required for writing ID, make sure your ID is unique for every single element, and there are tons of ways to select an element using JavaScript. You can check them out at JavaScript lessons.
3rd Jun 2019, 9:52 AM
Bug Slayer
0
Thanks
3rd Jun 2019, 2:43 PM
Dprincebh
Dprincebh - avatar