below is my php and html code
<div id="entry1" class="clonedInput">
<h3 id="reference" name="reference" class="heading-reference"></h3>
<div id="domain_section" class="notranslate">
<div class="form-group">
<label class="col-md-3 control-label label_pro" for="inputDefault">Product:</label>
<div class="col-md-6" >
<select class="form-control populate select_pro" name="select_pro[]" id="select_pro" data-plugin-selectTwo >
<?php
//`product_id`, `product_name`, `quantity`, `cat_id`, `banner`, `desc`SELECT * FROM `products`
$get_scategory = mysql_query("select * from products") or die(mysql_error());
$count_subcategory = mysql_num_rows($get_scategory);
if($count_subcategory > 0 ) {
?>
<option value="">Select product</option>
<?php
while($scategory_detail = mysql_fetch_array($get_scategory)) {
$product_id = $scategory_detail['product_id'];
$product_name = $scategory_detail['product_name'];
?>
<option value="<?php echo $product_id ; ?>"><?php echo $product_name ; ?></option>
<?php
}
}
?>
</select>
<!-- <select data-placeholder="Choose a Product" name="treatment1" id="prdt_scategory" class="prdt_scategory">
<option value="">Choose Product</option>
</select>-->
</div>
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label" for="inputDefault">or</label>
</div>
<div class="form-group">
<label class="col-md-3 control-label" for="inputDefault">Product </label>
<div class="col-md-6">
<input type="text" class="form-control select_prot" id="inputDefault" name="select_prot[]">
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label" for="inputDefault">Quantity </label>
<div class="col-md-6">
<input type="text" class="form-control select_qty" id="inputDefault" name="select_qty[]">
</div>
</div>
<div class="form-group">
<label class="col-md-3 control-label" for="inputDefault">Amount</label>
<div class="col-md-6">
<input type="text" class="form-control select_amt" id="inputDefault" name="select_amt[]">
</div>
</div>
</div>
and my jquery code is
<script>
$(function () {
$('#btnAdd').click(function () {
var num = $('.clonedInput').length, // how many "duplicatable" input fields we currently have
newNum = new Number(num + 1), // the numeric ID of the new input field being added
newElem = $('#entry' + num).clone().attr('id', 'entry' + newNum).fadeIn('fast');
newElem.find('.select_pro').attr('id', 'ID' + newNum + '_pro').attr('name', 'select_pro[]').val('');
newElem.find('.select_prot').attr('id', 'ID' + newNum + '_prot').attr('name', 'select_prot[]').val('');
newElem.find('.select_qty').attr('id', 'ID' + newNum + '_qty').attr('name', 'select_qty[]').val('');
newElem.find('.select_amt').attr('id', 'ID' + newNum + '_amt').attr('name', 'select_amt[]').val('');
$('#entry' + num).after(newElem);
$('#btnDel').attr('disabled', false);
});
$('#btnDel').click(function () {
var num = $('.clonedInput').length;
$('#entry' + num).slideUp('fast', function () {$(this).remove();
if (num -1 === 1)
$('#btnDel').attr('disabled', true);
$('#btnAdd').attr('disabled', false).prop('value', "+");});
return false;
$('#btnAdd').attr('disabled', false);
});
$('#btnDel').attr('disabled', true);
});
</script>
after clicking button i am getting select box but search option not working