zono

Untitled

Feb 5th, 2012
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. var lastItemNumber = /([0-9]+)$/.test($("#myList li:last").html()) ? RegExp.$1 : 0;
  2. var i = 0;
  3. while(i != 5) {
  4.         i++;
  5.         $("#myList").append("<li>List item " + (parseInt(lastItemNumber) + i) + "</li>");        
  6. }
Advertisement
Add Comment
Please, Sign In to add comment