MacLustre Posted June 18, 2012 Share Posted June 18, 2012 Hi I've seen id="demo" in a few tutorials, but there's no explanation of what "demo" means or why it's used. In on section of the tutorial on this Site, on one line it's used this way: <p id="demo"></p> and then further on it's used here: document.getElementById("demo").innerHTML=voteable; Why-What "demo"? Thanks in advance. Link to comment Share on other sites More sharing options...
Ingolme Posted June 18, 2012 Share Posted June 18, 2012 You could put anything you want there. That is just the name they decided to use. Link to comment Share on other sites More sharing options...
eTianbun Posted June 18, 2012 Share Posted June 18, 2012 (edited) Its an abbreviation for Demonstration, so it means, they are using the <p> tag to demonstrate how you can GET a reference to an element with id via javascript. Edited June 18, 2012 by CodeName Link to comment Share on other sites More sharing options...
eTianbun Posted June 18, 2012 Share Posted June 18, 2012 You could put anything you want there. That is just the name they decided to use. So as 'Ingolme' said, you can use any name you want. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now