$(this).insertAfter('class') code example Example: jquery insert after $( "<p>Test</p>" ).insertAfter( ".inner" );