Excelent! Thank you!...i have one question...why in fetch.php is so important to use class="btn btn-primary btn-xs edit" on button edit? It stops working without it (at least edit class needs to be used) ...which seems really strange
Thank you for this video. Do you have one where you explain how to create that beautiful web address? I'd appreciate it. Thank you in advance for your reply.
Hi Webslesson team Sir I have a big problem in a project inventory management which is how to show quantity in stock when i select order product , I tried this solution but it did not work -----------------------------------order.php $('#product_id').change(function(){ var product_id = document.getElementById("product_id").value; var btn_action = 'load_qte'; $.ajax({ url:"order_action.php", method:"POST", data:{product_id:product_id, btn_action:btn_action}, success:function(data) { $('#qte_stock').html(data); } }); }); html += ''; html += ''; html += ''; html += ''; html += ''; ----------------------------------------order_action.php if($_POST['btn_action'] == 'load_qte') { $output=' $qte = available_product_quantity($connect, $_POST["product_id"])'; }; echo $output; Where is the problem --------------------------------------------------------------------------i have this ugly solution--------------- which to add qte to select function fill_product_list_qte($connect) { $query = " SELECT * FROM product WHERE product_status = 'active' ORDER BY product_name ASC "; $statement = $connect->prepare($query); $statement->execute(); $result = $statement->fetchAll(); $output = ''; foreach($result as $row) { $product_id= $row["product_id"]; $qte = available_product_quantity($connect, $product_id); $output .= ' '.$row["product_name"].' --> '.$qte.' '; } return $output; } thank you a lot
Excelent! Thank you!...i have one question...why in fetch.php is so important to use class="btn btn-primary btn-xs edit" on button edit? It stops working without it (at least edit class needs to be used) ...which seems really strange
thank so much sir
Thank you for this video. Do you have one where you explain how to create that beautiful web address? I'd appreciate it. Thank you in advance for your reply.
thank you sir.....could you teach angular?
Thanks so much!
100! Amazing!!!!!!!!!!!!!!!!!!!!!
Hi Webslesson team
Sir I have a big problem in a project inventory management which is how to show quantity in stock
when i select order product , I tried this solution but it did not work
-----------------------------------order.php
$('#product_id').change(function(){
var product_id = document.getElementById("product_id").value;
var btn_action = 'load_qte';
$.ajax({
url:"order_action.php",
method:"POST",
data:{product_id:product_id, btn_action:btn_action},
success:function(data)
{
$('#qte_stock').html(data);
}
});
});
html += '';
html += '';
html += '';
html += '';
html += '';
----------------------------------------order_action.php
if($_POST['btn_action'] == 'load_qte')
{
$output=' $qte = available_product_quantity($connect, $_POST["product_id"])';
};
echo $output;
Where is the problem
--------------------------------------------------------------------------i have this ugly solution---------------
which to add qte to select
function fill_product_list_qte($connect)
{
$query = "
SELECT * FROM product
WHERE product_status = 'active'
ORDER BY product_name ASC
";
$statement = $connect->prepare($query);
$statement->execute();
$result = $statement->fetchAll();
$output = '';
foreach($result as $row)
{
$product_id= $row["product_id"];
$qte = available_product_quantity($connect, $product_id);
$output .= ' '.$row["product_name"].' --> '.$qte.' ';
}
return $output;
}
thank you a lot
It work up to 800 entry beyond that it get hang