So the code below will get the ID of the BODY elementL
var bodyId = document.body.id;
How can I get the ID of the HTML element using plain ole' JavaScript?
document.documentElement.id
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With