saadsaf
saadsaf

Reputation: 1451

JQuery append function to append button after a button

i have a button in html...

<div id=":ne" class="T-I J-J5-Ji ar7 nf T-I-ax7 L3" role="button" tabindex="0" aria-expanded="false" style="-webkit-user-select: none; " aria-haspopup="true"> <span class="Ykrj7b">More</span> </div> 

now i want to append a button after this button.plz help

Upvotes: 0

Views: 133

Answers (2)

Muhammad Ummar
Muhammad Ummar

Reputation: 3631

Try

$('#:ne').after('Your button code here');

Upvotes: 0

thecodeparadox
thecodeparadox

Reputation: 87073

var button = $("<button>Hi there</button>");

   $(button).insertAfter('#:ne');

or

$('#:ne').after(button);

Upvotes: 1

Related Questions