Hacked By AnonymousFox

Current Path : C:/AppServ/www/financial/
Upload File :
Current File : C:/AppServ/www/financial/saveeditfin1.php

<?php 
include("lib/connect.php");
include("lib/session.php");

if($System_Session_User_ID=="") {
echo "<SCRIPT LANGUAGE=\"JavaScript\">window.location = \"index.php\";alert(\"You must Login first.\");</SCRIPT>";
 } 


$sql="update fin_stepold set Step='$Step',No='$No',Detail='$Detail',Date1='$Date1',Date2='$Date2',Date3='$Date3',Comment='$Comment',Datetimesave=NOW() where Id='$Idedit'";
$query=mysql_query($sql);

$sqlc1="select Idfin from fin_stepold where Id='$Idedit'";
$queryc1=mysql_query($sqlc1);
$rowc1=mysql_fetch_array($queryc1);
$Idback=$rowc1[0];

//$sql="update fin_data set Result='4' where Id='$Idback'";
//$query=mysql_query($sql);

      if($Step=="2"){ $go="1"; }                         
      if($Step=="3"){ $go="1"; }                          
      if($Step=="4"){ $go="1"; }                      
      if($Step=="5"){ $go="1"; }                          
     if($Step=="6"){ $go="1"; }                            
      if($Step=="7"){ $go="2";}                            
      if($Step=="11"){ $go="2"; }                           
      if($Step=="12"){ $go="2"; }    
      if($Step=="39"){ $go="2"; }     
      if($Step=="40"){ $go="2"; }     
      if($Step=="41"){ $go="2"; }                           
      if($Step=="14"){ $go="2"; }              
      if($Step=="16"){ $go="2"; }                                    
      if($Step=="17"){ $go="2"; }                            
      if($Step=="20"){ $go="2"; }                                 
      if($Step=="21"){ $go="2"; }                        
      if($Step=="23"){ $go="2"; }                                    
      if($Step=="24"){ $go="2"; }                                 
      if($Step=="25"){ $go="2"; }                                
      if($Step=="26"){ $go="2"; }                    
      if($Step=="28"){ $go="3"; }                           
      if($Step=="29"){ $go="3";}  
      if($Step=="42"){ $go="3"; }                              
      if($Step=="31"){ $go="4"; }                           
      if($Step=="32"){ $go="4"; }    
      if($Step=="43"){ $go="4"; }    
      if($Step=="44"){ $go="4"; }  

$sql_check1="select Id from namestep where  No='$Step'";
$query_check1=mysql_query($sql_check1);
$row_check1=mysql_fetch_array($query_check1);
  
$sql_check="select step2 from fin_price where  Idfin='$Idback'";
$query_check=mysql_query($sql_check);
$num_check=mysql_num_rows($query_check);
$row_check=mysql_fetch_array($query_check);
$sql_check2="select Id from namestep where  No='$row_check[0]'";
$query_check2=mysql_query($sql_check2);
$row_check2=mysql_fetch_array($query_check2);

if($Date2!=""){
		if($num_check>0&&$row_check1[0]>$row_check2[0]){
		$sql="delete from fin_price where Idfin='$Idback'";
		$query=mysql_query($sql);
		
		$sql="insert into fin_price values (NULL,'$Idback','$go','$Step','')";
		$query=mysql_query($sql);
		}
}

			Header("Location:editdata.php?Id=$Idback");

?>
</body>
</html>

Hacked By AnonymousFox1.0, Coded By AnonymousFox