Mega Code Archive

 
Categories / JavaScript Tutorial / JQuery
 

Hard code value into each function

< html>   <head>     <script type='text/javascript' src='js/jquery-1.3.2.js'></script>     <script type='text/javascript'> $(document).ready(   function() {     $.each(       ['A', 'B', 'C', 'D'],       function() {         $('ul').append("<li>" + this + "</li>");          }     );   } );     </script>     <style type='text/css'> body {     font: 16px sans-serif; }     </style>   </head>   <body>      <ul>      </ul>   </body> </html>