Taking width attribute from children elements
<p>This is my first jQuery code. I want my ul element with class ".topnav" to have value of width attribute from the most width attribute li element that it contains. I have code like this and css for li elements <code>display:none</code>:</p>

<pre><code>$(function(){
    $('.topnav').each(function(){
      $(this).attr('width', Math.max($(this).children().each(function(){$(this).attr('width')})))});
   }) 
</code></pre>

<p>But it isn't work. Does someone could help? </p>
