jQuery insertAt

Try something like this:

$("#thelist li").eq(3).after("<li>A new item</li>");

With the eq function, you can get a specific index of the elements retrieved…then, insert the new list item after it.

In the above function, I am inserting a new item at position 4 (index 3).

More info about the function at the jQuery Docs

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)