javascript - What is the opposite of append in jquery? -


i use $('.posts').append('test') add 'test' last element in posts div. how can make first element?

use .prepend() like

$('.posts').prepend('test'); 

try link


Comments

Popular posts from this blog

assembly - 8086 TASM: Illegal Indexing Mode -

Java, LWJGL, OpenGL 1.1, decoding BufferedImage to Bytebuffer and binding to OpenGL across classes -

javascript - addthis share facebook and google+ url -