KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
Possible Duplicate: Checking if an html element is empty with jQuery I have an empty div like this: <div id="cartContent"></div> I need to check if it's empty. If it's empty it needs to return true and then some elements are added. If not it returns false and some other function executes. What's the best way to check if there are any elements in the div? Thanks
Tags (comma-separated)
Save Edits
Cancel