<form action="" method="post" id="enq_reply_form">
	<div class="form-group">
    	<input type="hidden" name="enq_date" value="<?php echo date("d M",strtotime($enq->enq_datetime));?>" />
    	<input type="hidden" name="enq_id" value="<?php echo $enq->enq_id;?>" />
    	<label>Reply Email</label>
    	<input type="email" class="form-control" name="email" value="<?php echo $enq->enq_mail;?>" />
    </div>
	<div class="form-group">
    	<label>Reply Message</label>
        <textarea class="form-control" name="reply" required rows="5"></textarea>
    </div>
    <button type="submit" class="btn btn-block btn-warning">Send Reply</button>
</form>
 <script>



	$(document).ready(function(){
		$("#enq_reply_form").submit(function(e){e.preventDefault();
			var formdata=$(this).serialize();
			$.ajax({
			 type: "POST",
			 url: '<?php echo base_url();?>swadmin/ajax_reply_submit',
			 data: {formdata:formdata},
			 success: function(res){
					alert(res);
				}
			 });
		});
	});
	</script>