Although don't feel obliged to litter your code with unnecessary IDs if you just want to access the elements via Javascript; instead, use something like Simon Willison's
getElementsBySelector() to select the element(s) via a CSS selector. So, with the markup:
Code:
<div id="header">
<h1>Title</h1>
<ul>
<li>lalala</li>
<li><a href="#">lol</a></li>
</ul>
</div>
You don't need to add an otherwise unnecessary ID to the <ul> to access it via Javascript, you can access it just as you would with CSS:
Code:
var nav = document.getElementsBySelector('#header ul');
Leaner markup + unobtrusive Javascript = Lovely