<?php if(isset($_POST['submit'])) { $branch=$_POST['Region']; if($_POST['Region'] =='' || $_POST['Region']=='ALL') { $Qry="select Branch_code,Palmtec_id,Download_status from tbl_download order by Branch_code,Palmtec_id"; } else { $Qry="select Branch_code,Palmtec_id,Download_status from tbl_download where Branch_code='$branch' order by Branch_code,Palmtec_id"; } $macid=$_POST['brmacid']; if($_POST['brmacid']=='' || $_POST['brmacid']=='ALL') { $Qry.=""; } else { $Qry="select Branch_code,Palmtec_id,Download_status from tbl_download where Branch_code='$branch' and Palmtec_id='$macid' order by Branch_code,Palmtec_id"; } $up=$_POST['up']; if($_POST['up']=='0' || $_POST['up']=='1') { $Qry="update tbl_download set Download_status='$up' where Branch_code='$branch' and Palmtec_id='$macid' (select Branch_code,Palmtec_id,Download_status from tbl_download where Branch_code='$branch' and Palmtec_id='$macid') "; } $Res = mssql_query($Qry); //echo $Qry; echo "<table border ='1' align ='center' cellpadding='1' cellspacing='1' width='900' bgcolor='#FFFFFF' style='border:1px solid #0080FF;' >" ; echo "<tr><th style='background:#58ACFA;'>S.No</th> <th style='background:#58ACFA;'>Branch_code</th> <th style='background:#58ACFA;'>Palmtec_id</th> <th style='background:#58ACFA;'>Download_status</th></tr>";
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)