Viewing file: ProjectOutput1.php (49.31 KB) -rw-r--r-- Select action/file-type: (+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php session_start(); if (session_is_registered("valid_user")&&session_is_registered("password")) { $Username = $valid_user; $Password = $password; include("../../../include/FunctionDB.php"); ConnectDB(); ////// Manage $sql = "Select * From project_tb"; $result= mysql_query($sql) or die("Error".mysql_error()); $Total = mysql_num_rows($result); /////// educate $sql_2 = "Select * From edu_project_tb"; $result_2 = mysql_query($sql_2) or die("Error".mysql_error()); $Total2= mysql_num_rows($result_2); ////// Develop $sql_3 = "Select * From edu_service_tb"; $result_3= mysql_query($sql_3) or die("Error".mysql_error()); $Total3 = mysql_num_rows($result_3); ///// Stdac $sql_4 = "Select * From std_activity_tb"; $result_4= mysql_query($sql_4) or die("Error".mysql_error()); $Total4 = mysql_num_rows($result_4); ////// Research $sql_5 = "Select * From foreign_relation_tb"; $result_5= mysql_query($sql_5) or die("Error".mysql_error()); $Total5 = mysql_num_rows($result_5); ///// Qa $sql_7 = "Select * From qa_project_tb"; $result_7= mysql_query($sql_7) or die("Error".mysql_error()); $Total7 = mysql_num_rows($result_7); $AllTotal = $Total + $Total2 + $Total3 + $Total4 + $Total5 + $Total7; ?> <html> <head> <title>Display Project List </title> <link rel="stylesheet" href="../../../css/style1.css" type="text/css"> <meta http-equiv="Content-Type" content="text/html; charset=windows-874"></head> <body bgcolor="#FFFFFF"> <table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" style="border:1px solid gray"> <tr bgcolor="#CBE4D9" > <td colspan="4"> <div align="center"><font color="#000000" size="4" face="Tahoma"><strong>สรุปผลการจัดโครงการ/กิจกรรม แยกตามฝ่ายงาน </strong></font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td width="221" align="center" bgcolor="#CCCCCC" style="border:1px solid gray"><font color="#333333" size="2" face="Tahoma"><b>ฝ่ายงาน</b></font></td> <td width="254" align="center" style="border:1px solid gray"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#CCCCCC"> <tr bgcolor="#DBFFB7"> <td colspan="3"> <div align="center"><font size="2" face="Tahoma">จัดทำเสร็จตามเวลาที่กำหนด</font></div></td> </tr> <tr bgcolor="#FDFCF2"> <td width="33%"> <div align="center"><font size="2" face="Tahoma">เสร็จทัน</font></div></td> <td width="33%"> <div align="center"><font size="2" face="Tahoma">ไม่เสร็จ</font></div></td> <td width="34%"> <div align="center"><font size="2" face="Tahoma">ไม่ได้ทำ</font></div></td> </tr> </table></td> <td width="259" align="center" style="border:1px solid gray"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#CCCCCC"> <tr bgcolor="#FFFFC1"> <td colspan="3"> <div align="center"><font size="2" face="Tahoma">งบประมาณที่ใช้เทียบกับที่ประมาณการ</font></div></td> </tr> <tr bgcolor="#FEFDF3"> <td width="30%"> <div align="center"><font size="2" face="Tahoma">น้อยกว่า</font></div></td> <td width="30%"> <div align="center"><font size="2" face="Tahoma">มากกว่า</font></div></td> <td width="30%" bgcolor="#FEFDF3"> <div align="center"><font size="2" face="Tahoma">ไม่ได้ทำ</font></div></td> </tr> </table></td> <td width="245" align="center" style="border:1px solid gray"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#CCCCCC"> <tr bgcolor="#E8FFFF"> <td colspan="3"> <div align="center"><font size="2" face="Tahoma">การบรรลุวัตุประสงค์ของโครงการ</font></div></td> </tr> <tr bgcolor="#FEFDF3"> <td width="30%"> <div align="center"><font size="2" face="Tahoma">บรรลุ</font></div></td> <td width="30%"> <div align="center"><font size="2" face="Tahoma">ไม่บรรลุ</font></div></td> <td width="30%"> <div align="center"><font size="2" face="Tahoma">ไม่ได้ทำ</font></div></td> </tr> </table></td> </tr> <tr bordercolor="#EEEEEE" > <td align=center bgcolor="#EEEEEE" > <div align="center"><font color="#003300" size="2" face="Tahoma"> งานบริหาร </font></div></td> <td bgcolor="#eeeeee"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"> <div align="center"> <font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From project_tb Where Result_oper ='1'"; $result1 = mysql_query($sql1); $Count1 = mysql_num_rows($result1); echo "$Count1"; ?> </font></div></td> <td width="30%" bgcolor="#EEEEEE"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql2 = "Select * From project_tb Where Result_oper ='2'"; $result2 = mysql_query($sql2); $Count2 = mysql_num_rows($result2); echo "$Count2"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql3 = "Select * From project_tb Where Result_oper ='3'"; $result3 = mysql_query($sql3) or die("Error".mysql_error()); $Count3 = mysql_num_rows($result3); echo "$Count3"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php // $A11 = $rs1[Count1]; $Percent1 = ($Count1 * 100) / $Total; echo number_format($Percent1,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php // $A11 = $rs1[Count1]; $Percent2 = ($Count2 * 100) / $Total; echo number_format($Percent2,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php // $A11 = $rs1[Count1]; $Percent3 = ($Count3 * 100) / $Total; echo number_format($Percent3,2,'.',','); ?> % </font></div></td> </tr> </table></td> <td bgcolor="#eeeeee" ><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"> <div align="center"> <font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From project_tb Where Dif_result <= Budget"; $result4 = mysql_query($sql4) or die("Error".mysql_error()); $Count4 = mysql_num_rows($result4); echo "$Count4"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From project_tb Where Dif_result > Budget"; $result5 = mysql_query($sql5) or die("Error".mysql_error()); $Count5 = mysql_num_rows($result5); echo "$Count5"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From project_tb Where Result_oper ='3'"; $result6 = mysql_query($sql6) or die("Error"); $Count6 = mysql_num_rows($result6); echo "$Count6"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td height="16"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php // $A11 = $rs1[Count1]; $Percent4 = ($Count4 * 100) / $Total; echo number_format($Percent,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php // $A11 = $rs1[Count1]; $Percent5 = ($Count5 * 100) / $Total; echo number_format($Percent5,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent6 = ($Count6 * 100) / $Total; echo number_format($Percent6,2,'.',','); ?> % </font></div></td> </tr> </table></td> <td bgcolor="#FFFFFF" > <table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"> <div align="center"> <font color="#0033CC" size="2" face="Tahoma"> <?php $sql7 = "Select * From project_tb Where Dif_result <= Budget"; $result7= mysql_query($sql7) or die("Error".mysql_error()); $Count7 = mysql_num_rows($result7); echo "$Count7"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql8 = "Select * From project_tb Where Dif_result <= Budget"; $result8= mysql_query($sql8) or die("Error".mysql_error()); $Count8 = mysql_num_rows($result8); echo "$Count8"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql9 = "Select * From project_tb Where Dif_result <= Budget"; $result9= mysql_query($sql9) or die("Error".mysql_error()); $Count9 = mysql_num_rows($result9); echo "$Count9"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td height="16"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent7 = ($Count7 * 100) / $Total; echo number_format($Percent7,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> % <?php $Percent8 = ($Count8 * 100) / $Total; echo number_format($Percent8,2,'.',','); ?> </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent9 = ($Count9 * 100) / $Total; echo number_format($Percent9,2,'.',','); ?> % </font></div></td> </tr> </table></td> </tr> <tr bordercolor="#EEEEEE"> <td align="center" bgcolor="#FFFFFF" > <div align="center"><font color="#003366" size="2" face="Tahoma"> งานวิชาการ </font></div></td> <td bgcolor="#FFFFFF"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFFF"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From edu_project_tb Where Result_oper ='1'"; $result21 = mysql_query($sql1); $Count21 = mysql_num_rows($result21); echo "$Count21"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From edu_project_tb Where Result_oper ='2'"; $result1 = mysql_query($sql1); $Count22 = mysql_num_rows($result1); echo "$Count22"; ?> </font></div></td> <td width="30%" bgcolor="#FFFFFF"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql3 = "Select * From edu_project_tb Where Result_oper ='3'"; $result3 = mysql_query($sql3) or die("Error".mysql_error()); $Count23 = mysql_num_rows($result3); echo "$Count23"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php // $A11 = $rs1[Count1]; $Percent21 = ($Count21 * 100) / $Total2; echo number_format($Percent21,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php // $A11 = $rs1[Count1]; $Percent22 = ($Count22 * 100) / $Total2; echo number_format($Percent22,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php // $A11 = $rs1[Count1]; $Percent23 = ($rs1[Count23] * 100) / $Total2; echo number_format($Percent23,2,'.',','); ?> %</font></div></td> </tr> </table></td> <td bgcolor="#FFFFFF" ><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFFF"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From edu_project_tb Where Dif_result <= Budget"; $result24 = mysql_query($sql4) or die("Error".mysql_error()); $Count24 = mysql_num_rows($result24); echo "$Count24"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From edu_project_tb Where Dif_result > Budget"; $result25 = mysql_query($sql5) or die("Error".mysql_error()); $Count25 = mysql_num_rows($result25); echo "$Count25"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From edu_project_tb Where Dif_result > Budget AND Result_oper ='3'"; $result26 = mysql_query($sql6) or die("Error"); $Count26 = mysql_num_rows($result26); echo "$Count26"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent44 = ($Count24 * 100) / $Total4; echo number_format($Percent44,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent25 = ($Count25 * 100) / $Total4; echo number_format($Percent25,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent26 = ($Count26 * 100) / $Total4; echo number_format($Percent26,2,'.',','); ?> %</font></div></td> </tr> </table></td> <td bgcolor="#FFFFFF" ><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFFF"> <td width="30%"> <div align="center"> <font color="#0033CC" size="2" face="Tahoma"> <?php $sql7 = "Select * From edu_project_tb Where Dif_result <= Budget"; $result27= mysql_query($sql7) or die("Error".mysql_error()); $Count27 = mysql_num_rows($result27); echo "$Count27"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql8 = "Select * From edu_project_tb Where Dif_result <= Budget"; $result28= mysql_query($sql8) or die("Error".mysql_error()); $Count28 = mysql_num_rows($result28); echo "$Count28"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql9 = "Select * From edu_project_tb Where Dif_result <= Budget"; $result29= mysql_query($sql9) or die("Error".mysql_error()); $Count29 = mysql_num_rows($result29); echo "$Count29"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td height="16"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent27 = ($Count27 * 100) / $Total; echo number_format($Percent27,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent28= ($Count28 * 100) / $Total; echo number_format($Percent28,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent92 = ($Count92 * 100) / $Total; echo number_format($Percent92,2,'.',','); ?> % </font></div></td> </tr> </table></td> </tr> <tr bordercolor="#EEEEEE" > <td align=center bgcolor="#EEEEEE" > <div align="center"><font color="#003366" size="2" face="Tahoma"> งานพัฒนาบุคลากร </font></div></td> <td bgcolor="#eeeeee"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"><div align="center"> <font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From edu_service_tb Where Result_oper ='1'"; $result31 = mysql_query($sql1); $Count31 = mysql_num_rows($result31); echo "$Count31"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From edu_service_tb Where Result_oper ='2'"; $result32 = mysql_query($sql1); $Count32 = mysql_num_rows($result32); echo "$Count32"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From edu_service_tb Where Result_oper ='3'"; $result33 = mysql_query($sql1); $Count33 = mysql_num_rows($result33); echo "$Count33"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent31 = ($Count31 * 100) / $Total3; echo number_format($Percent31,2,'.',','); ?> % </font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent32 = ($Count32 * 100) / $Total3; echo number_format($Percent32,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent33 = ($Count33 * 100) / $Total3; echo number_format($Percent33,2,'.',','); ?> %</font></div></td> </tr> </table></td> <td bgcolor="#eeeeee" ><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From edu_service_tb Where Dif_result <= Budget"; $result34 = mysql_query($sql4) or die("Error".mysql_error()); $Count34 = mysql_num_rows($result34); echo "$Count34"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From edu_service_tb Where Dif_result > Budget"; $result35 = mysql_query($sql5) or die("Error".mysql_error()); $Count35 = mysql_num_rows($result35); echo "$Count35"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From edu_service_tb Where Result_oper ='3'"; $result36 = mysql_query($sql6) or die("Error"); $Count36 = mysql_num_rows($result36); echo "$Count36"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent34 = ($Count34 * 100) / $Total3; echo number_format($Percent34,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent35 = ($Count35 * 100) / $Total3; echo number_format($Percent35,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent36 = ($Count36 * 100) / $Total3; echo number_format($Percent36,2,'.',','); ?> % </font></div></td> </tr> </table></td> <td bgcolor="#eeeeee" ><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From edu_service_tb Where Dif_result <= Budget"; $result37 = mysql_query($sql4) or die("Error".mysql_error()); $Count37 = mysql_num_rows($result37); echo "$Count37"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From edu_service_tb Where Dif_result > Budget"; $result38 = mysql_query($sql5) or die("Error".mysql_error()); $Count38 = mysql_num_rows($result38); echo "$Count38"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From edu_service_tb Where Result_oper ='3'"; $result39 = mysql_query($sql6) or die("Error"); $Count39 = mysql_num_rows($result39); echo "$Count39"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent37 = ($Count37 * 100) / $Total3; echo number_format($Percent37,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent38 = ($Count38 * 100) / $Total3; echo number_format($Percent38,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent39 = ($Count39 * 100) / $Total3; echo number_format($Percent39,2,'.',','); ?> % </font></div></td> </tr> </table></td> </tr> <tr bordercolor="#EEEEEE"> <td align="center" bgcolor="#FFFFFF" > <div align="center"><font color="#003366" size="2" face="Tahoma"> งานกิจการนักศึกษา </font></div></td> <td bgcolor="#FFFFFF"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFFF"> <td width="30%"> <div align="center"> <font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From std_activity_tb Where Result_oper ='1'"; $result1 = mysql_query($sql1); $Count41 = mysql_num_rows($result1); echo "$Count41"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From std_activity_tb Where Result_oper ='2'"; $result1 = mysql_query($sql1); $Count42 = mysql_num_rows($result1); echo "$Count42"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From std_activity_tb Where Result_oper ='3'"; $result43 = mysql_query($sql1); $Count43 = mysql_num_rows($result43); echo "$Count43"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent41 = ($Count41 * 100) / $Total4; echo number_format($Percent41,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent42 = ($Count42 * 100) / $Total4; echo number_format($Percent42,2,'.',','); ?> %</font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent43 = ($Count43 * 100) / $Total4; echo number_format($Percent43,2,'.',','); ?> %</font></div></td> </tr> </table></td> <td bgcolor="#FFFFFF" ><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFFF"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From std_activity_tb Where Dif_result <= Budget"; $result44 = mysql_query($sql4) or die("Error".mysql_error()); $Count44 = mysql_num_rows($result44); echo "$Count44"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From std_activity_tb Where Dif_result > Budget"; $result45 = mysql_query($sql5) or die("Error".mysql_error()); $Count45 = mysql_num_rows($result45); echo "$Count45"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From std_activity_tb Where Dif_result > Budget AND Result_oper ='3'"; $result46 = mysql_query($sql6) or die("Error"); $Count46 = mysql_num_rows($result46); echo "$Count46"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent44 = ($Count44 * 100) / $Total4; echo number_format($Percent44,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent45 = ($Count45 * 100) / $Total4; echo number_format($Percent45,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent46 = ($Count46 * 100) / $Total4; echo number_format($Percent46,2,'.',','); ?> %</font></div></td> </tr> </table></td> <td bgcolor="#FFFFFF" ><table width="100%" border="0" align="center" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFFF"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From std_activity_tb Where Dif_result <= Budget"; $result47 = mysql_query($sql4) or die("Error".mysql_error()); $Count47 = mysql_num_rows($result47); echo "$Count47"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From std_activity_tb Where Dif_result > Budget"; $result48 = mysql_query($sql5) or die("Error".mysql_error()); $Count48 = mysql_num_rows($result48); echo "$Count48"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From std_activity_tb Where Dif_result > Budget AND Result_oper ='3'"; $result49 = mysql_query($sql6) or die("Error"); $Count49 = mysql_num_rows($result49); echo "$Count49"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent47 = ($Count47 * 100) / $Total4; echo number_format($Percent47,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent48 = ($Count48 * 100) / $Total4; echo number_format($Percent48,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent49 = ($Count49 * 100) / $Total4; echo number_format($Percent49,2,'.',','); ?> %</font></div></td> </tr> </table></td> </tr> <tr bordercolor="#EEEEEE" > <td align=center bgcolor="#FFFFCC" > <div align="center"><font color="#003366" size="2" face="Tahoma"> งานวิจัย</font></div></td> <td bgcolor="#eeeeee"><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From foreign_relation_tb Where Result_oper ='1'"; $result51 = mysql_query($sql1); $Count51 = mysql_num_rows($result51); echo "$Count51"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From foreign_relation_tb Where Result_oper ='2'"; $result52 = mysql_query($sql1); $Count52 = mysql_num_rows($result52); echo "$Count52"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From foreign_relation_tb Where Result_oper ='3'"; $result53 = mysql_query($sql1); $Count53 = mysql_num_rows($result53); echo "$Count53"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent51 = ($Count51 * 100) / $Total5; echo number_format($Percent51,2,'.',','); ?> % </font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent52 = ($Count52 * 100) / $Total5; echo number_format($Percent52,2,'.',','); ?> % </font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent53 = ($Count53 * 100) / $Total5; echo number_format($Percent53,2,'.',','); ?> % </font></div></td> </tr> </table></td> <td bgcolor="#eeeeee" ><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From foreign_relation_tb Where Dif_result <= Budget"; $result54 = mysql_query($sql4) or die("Error".mysql_error()); $Count54 = mysql_num_rows($result54); echo "$Count54"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From foreign_relation_tb Where Dif_result > Budget"; $result55 = mysql_query($sql5) or die("Error".mysql_error()); $Count55 = mysql_num_rows($result55); echo "$Count55"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From foreign_relation_tb Where Dif_result > Budget AND Result_oper ='3'"; $result56 = mysql_query($sql6) or die("Error"); $Count56 = mysql_num_rows($result56); echo "$Count56"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent54 = ($Count54 * 100) / $Total5; echo number_format($Percent54,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent55 = ($Count55 * 100) / $Total5; echo number_format($Percent55,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent56 = ($Count56 * 100) / $Total5; echo number_format($Percent56,2,'.',','); ?> %</font></div></td> </tr> </table></td> <td bgcolor="#eeeeee" ><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#EEEEEE"> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From foreign_relation_tb Where Dif_result <= Budget"; $result57= mysql_query($sql4) or die("Error".mysql_error()); $Count57 = mysql_num_rows($result57); echo "$Count57"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From foreign_relation_tb Where Dif_result > Budget"; $result58 = mysql_query($sql5) or die("Error".mysql_error()); $Count58 = mysql_num_rows($result58); echo "$Count58"; ?> </font></div></td> <td width="30%"><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From foreign_relation_tb Where Dif_result > Budget AND Result_oper ='3'"; $result59 = mysql_query($sql6) or die("Error"); $Count59 = mysql_num_rows($result59); echo "$Count59"; ?> </font></div></td> </tr> <tr bgcolor="#EEEEEE"> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent57 = ($Count57 * 100) / $Total5; echo number_format($Percent57,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent58 = ($Count58 * 100) / $Total5; echo number_format($Percent58,2,'.',','); ?> %</font></div></td> <td><div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent59 = ($Count59 * 100) / $Total5; echo number_format($Percent59,2,'.',','); ?> %</font></div></td> </tr> </table></td> </tr> <tr bordercolor="#EEEEEE" > <td align=center bgcolor="#FFFFFF" > <div align="center"><font color="#003366" size="2" face="Tahoma"> งานประกัน </font></div></td> <td bgcolor="#eeeeee"><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#FFFFFF"> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From qa_project_tb Where Result_oper ='1'"; $result71 = mysql_query($sql1); $Count71 = mysql_num_rows($result71); echo "$Count71"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From qa_project_tb Where Result_oper ='2'"; $result72 = mysql_query($sql1); $Count72 = mysql_num_rows($result72); echo "$Count72"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql1 = "Select * From qa_project_tb Where Result_oper ='3'"; $result73 = mysql_query($sql1); $Count73 = mysql_num_rows($result73); echo "$Count73"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent71 = ($Count71 * 100) / $Total7; echo number_format($Percent71,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent72 = ($Count72 * 100) / $Total7; echo number_format($Percent72,2,'.',','); ?> % </font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent73 = ($Count73 * 100) / $Total7; echo number_format($Percent73,2,'.',','); ?> % </font></div></td> </tr> </table></td> <td bgcolor="#eeeeee" ><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#FFFFFF"> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From qa_project_tb Where Dif_result <= Budget"; $result74 = mysql_query($sql4) or die("Error".mysql_error()); $Count74 = mysql_num_rows($result74); echo "$Count74"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From qa_project_tb Where Dif_result > Budget"; $result75 = mysql_query($sql5) or die("Error".mysql_error()); $Count75 = mysql_num_rows($result75); echo "$Count75"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From qa_project_tb Where Dif_result > Budget AND Result_oper ='3'"; $result76 = mysql_query($sql6) or die("Error"); $Count76 = mysql_num_rows($result76); echo "$Count76"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent74 = ($Count74 * 100) / $Total7; echo number_format($Percent74,2,'.',','); ?> %</font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent75 = ($Count75 * 100) / $Total7; echo number_format($Percent75,2,'.',','); ?> %</font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent76 = ($Count76 * 100) / $Total7; echo number_format($Percent76,2,'.',','); ?> %</font></div></td> </tr> </table></td> <td bgcolor="#eeeeee" ><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#EEEEEE"> <tr bgcolor="#FFFFFF"> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql4 = "Select * From qa_project_tb Where Dif_result <= Budget"; $result77= mysql_query($sql4) or die("Error".mysql_error()); $Count77 = mysql_num_rows($result77); echo "$Count77"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql5 = "Select * From qa_project_tb Where Dif_result > Budget"; $result78 = mysql_query($sql5) or die("Error".mysql_error()); $Count78 = mysql_num_rows($result78); echo "$Count78"; ?> </font></div></td> <td width="30%"> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $sql6 = "Select * From qa_project_tb Where Dif_result > Budget AND Result_oper ='3'"; $result79 = mysql_query($sql6) or die("Error"); $Count79 = mysql_num_rows($result79); echo "$Count79"; ?> </font></div></td> </tr> <tr bgcolor="#FFFFFF"> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent77 = ($Count77 * 100) / $Total7; echo number_format($Percent77,2,'.',','); ?> %</font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent78 = ($Count78 * 100) / $Total7; echo number_format($Percent78,2,'.',','); ?> %</font></div></td> <td> <div align="center"><font color="#0033CC" size="2" face="Tahoma"> <?php $Percent79 = ($Count79 * 100) / $Total7; echo number_format($Percent79,2,'.',','); ?> %</font></div></td> </tr> </table></td> </tr> <tr bordercolor="#EEEEEE"> <td align="center" bgcolor="#FFFFFF" > <div align="left"><font color="#990099" size="2" face="Tahoma"> <a href="../../manage_depart/Project&Acc/ProjectDetail.php?Project_code=<?=$row["Project_code"]?>"title="Click to see Detail" class="d"> </a></font> <table width="100%" height="40" border="0" cellpadding="0" cellspacing="1" style="border:1px solid gray"> <tr> <td bgcolor="#FFFFF0"> <div align="center"><strong><font size="2" face="Tahoma">รวม</font></strong></div></td> </tr> <tr> <td><div align="center"><strong><font size="2" face="Tahoma">ร้อยละ</font></strong></div></td> </tr> </table> </div></td> <td bgcolor="#FFFFFF"><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFF0"> <td width="30%" bgcolor="#FFFFF0"> <div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum1 =$Count1 + $Count21+ $Count31 + $Count41+ $Count51 + $Count71 ; echo number_format($Sum1,2,'.',','); ?> </font></strong></div></td> <td width="30%"><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum2 =$Count2 +$Count22 + $Count32 + $Count42+ $Count52 + $Count72 ; echo number_format($Sum2,2,'.',','); ?> </font></strong></div></td> <td width="30%" bgcolor="#FFFFF0"><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum3 =$Count3 + $Count23 + $Count33 + $Count43 + $Count53 + $Count73 ; echo number_format($Sum3,2,'.',','); ?> </font></strong></div></td> </tr> <tr bgcolor="#FFFFFF"> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum1 =($Sum1 * 100) / $AllTotal; echo number_format($PerSum1,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum2 =($Sum2 * 100) / $AllTotal; echo number_format($PerSum2,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum3 =($Sum3 * 100) / $AllTotal; echo number_format($PerSum3,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> </tr> </table></td> <td bgcolor="#FFFFFF" ><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFF0"> <td width="30%"><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum4 =$Count4 + $Count24 + $Count34 + $Count44 + $Count54 + $Count74 ; echo number_format($Sum4,2,'.',','); ?> </font></strong></div></td> <td width="30%"><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum5 =$Count5 + $Count25 + $Count35 + $Count45 + $Count55 + $Count75 ; echo number_format($Sum5,2,'.',','); ?> </font></strong></div></td> <td width="30%"><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum6 =$Count6 + $Count26 + $Count36 + $Count46 + $Count56 + $Count76 ; echo number_format($Sum6,2,'.',','); ?> </font></strong></div></td> </tr> <tr bgcolor="#FFFFFF"> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum4 =($Sum4 * 100) / $AllTotal; echo number_format($PerSum4,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum5 =($Sum5 * 100) / $AllTotal; echo number_format($PerSum5,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum6 =($Sum6 * 100) / $AllTotal; echo number_format($PerSum6,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> </tr> </table></td> <td bgcolor="#FFFFFF" ><table width="100%" border="0" cellpadding="0" cellspacing="1" bgcolor="#FFFFFF"> <tr bgcolor="#FFFFF0"> <td width="30%"><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum7 =$Count7+ $Count27 + $Count37 + $Count47 + $Count57 + $Count77 ; echo number_format($Sum7,2,'.',','); ?> </font></strong></div></td> <td width="30%"><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum8 =$Count8 + $Count28 + $Count38 + $Count48 + $Count58 + $Count78 ; echo number_format($Sum8,2,'.',','); ?> </font></strong></div></td> <td width="30%"><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $Sum9 =$Count9 + $Count29 + $Count39 + $Count49 + $Count59 + $Count79 ; echo number_format($Sum9,2,'.',','); ?> </font></strong></div></td> </tr> <tr bgcolor="#FFFFFF"> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum7 =($Sum7 * 100) / $AllTotal; echo number_format($PerSum7,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum8 =($Sum8 * 100) / $AllTotal; echo number_format($PerSum8,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> <td><div align="center"><strong><font color="#FF0000" size="2" face="Tahoma"> <?php $PerSum9 =($Sum9 * 100) / $AllTotal; echo number_format($PerSum9,2,'.',','); ?> </font></strong><font color="#FF0000" size="2" face="Tahoma">%<strong> </strong></font></div></td> </tr> </table></td> </tr> <tr bgcolor="#CBE4D9"> <td colspan="4" align="center"> </td> </table> <table width="100%" border="0" cellpadding="0" cellspacing="1" bordercolor="#99CCFF"> <tr> <td align="right" bordercolor="#CCCCCC" class="Tahoma11"> <div align="center"><font color="#FFFFFF"> <font color="#FFFFFF" size="3" face="MS Sans Serif"><strong> <font color="#0033CC" size="2" face="Tahoma"><?php echo $Num_Pages;?></font></strong></font><font size="2" face="Tahoma"><strong> </strong><font color="#000000">หน้า</font></font> <font color="#0033CC" size="2" face="Tahoma"> <strong> <?php if ($Pre_Page) echo"<a href=\"$PHP_SELF?Page=$Pre_Page\" class=\"PageLink\"><font =\"Ms San serif\" size=\"3\"><b><< Previus</b> </font></a>";
for($i=1;$i<=$Num_Pages;$i++) { if($i != $Page) echo" [<a href=\"$PHP_SELF?Page=$i\" class=\"PageLink\"><font =\"Ms San serif\" size=\"3\"><b>$i</b></font></a>] "; else echo"<b>$i</b>"; } if($Page != $Num_Pages) echo"<a href=\"$PHP_SELF?Page=$Next_Page\" class=\"PageLink\"><font =\"Ms San serif\" size=\"3\"><b> Next >></b> </font></a>"; ?> </strong></font> </font> </div></td> </tr> </table> </html> <?php } else { echo"<body bgcolor=\"#CCCCCC\">"; echo"<meta http-equiv=\"refresh\" content=\"3;URL=../../logout.php\" target=\"mainFrame\">\n"; echo"<center>"; echo"<br><br><br><b><font face=\"Tahoma\" size=\"4\" color=\"#FF0000\">Please Login</font> </b><br>"; echo"<br><br><font face=\"Tahoma\" size=\"10\" color=\"#000000\"> ERROR 404 PERMISION DENY</font><br>"; echo"<br><font face=\"Tahoma\" size=\"4\" color=\"#000000\"> คุณไม่มีสิทธ์ใช้งาน</font>"; echo"</center>"; echo"</body>"; } ?>
|