I have some code that makes a <p> element appear when a button is clicked using jquery. If the button is pressed twice I would like for another <p> element to appear. Right now that doesn’t happen (the <p> only appears once).
JQUERY:
$(document).ready(function(){
$("#add").click(function() {
$(".input").css("display","block");
});
});
HTML:
<p class='input' style='display: none;'>
text here
</p>
<input type='button' value='Add class' id='add'>
If you have more than one hidden
pwith class ofinputyou can try:DEMO