<?php $id=$_REQUEST['CID']+1; ?> <div style="float:left;width:100%"> <div style="float:left;width:100%"> <input type="text" style="width:140px;" name="add_qualification[]" /><a href='javascript: if(confirm("Are You Sure?")) { removeElement("myDiv2","my<?php echo $id; ?>myDiv2"); }'><img src="images/delete.png" style="border:none;" width="10" height="10" /></a></div> </div>