MINI SHELL

Server : Apache/2.2.2 (Fedora)
System : Linux App1.pathumtani.go.th 2.6.20-1.2320.fc5smp #1 SMP Tue Jun 12 19:40:16 EDT 2007 i686
User : apache ( 48)
PHP Version : 5.2.9
Disable Function : NONE
Directory :  /var/www/html/pathumthani_eoffice/application/bin/auction_news/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : /var/www/html/pathumthani_eoffice/application/bin/auction_news/qq.php
<? 
include("chk_permission.php"); 
include("../../config/config.inc.php");
include("libary/function.php"); ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874" />
<link href="../../common/style.css" rel="stylesheet" type="text/css">
<link href="libary/tabber/tabber.css" rel="stylesheet" type="text/css">
<script language="javascript" src="libary/tabber/tabber.js"></script>
<script language="javascript" src="libary/popcalendar.js"></script>
<script language="javascript" src="libary/bbcode.js"></script>
<title>Untitled Document</title>
<style type="text/css">
<!--
.style1 {color: #FF0000; }
.tabber {display:block; }
-->
</style>
</head>

<body><input name="" type="hidden" value="<?=$action;?>" />
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="normal">
  <tr>
    <td width="90%" height="23" bgcolor="#eeeeee">&nbsp;<img src="../../images/arrow-b.gif" border="0" align="absmiddle" />&nbsp;<b class="normal_blue">Main Menu&nbsp;<font class="normal_black">:</font></b>&nbsp;ระบบข่าวประกวดราคา
      <hr color="#cdcdcd" /></td>
    <td width="10%" height="23" bgcolor="#eeeeee">&nbsp;<a href="../control/index.php?action=logout">LOGOUT</a>
        <hr color="#cdcdcd" /></td>
  </tr>
  <tr>
    <td colspan="2" valign="top"><br />
        <!-- ------------------------Main Body------------------------------- -->
        <?
if(($action == "add") || ($action == "edit")){
	
	if($action == "edit"){

	if($user_permission != 0 ){
	
		$msg = "<font class=\"normal_blue\">Note</font><br><br>ไม่สามารถแก้ไขข้อมูลการประกวดราคาได้<br>ระบบยินยอมให้ผู้ดูแลเท่านั้นที่แก้ไขข้อมูลได้<hr color=\"#B0D5FF\">";
		$msg = $msg."<input type=\"button\" name=\"button\" value=\"ย้อนกลับ\" style=\"width:100px; background-color:#ffffff;\" onClick=\"window.location.replace('?page=$page')\" class=\"input\">";		echo attach_status($msg);			
		exit;
		
	}
	
	
		$sql_edit = mysql_query("select * from `auction` where id = '$id'") or die("Query line " . __LINE__ . " Error<hr>".mysql_error());
		$ers = mysql_fetch_assoc($sql_edit);
		$eexpire_day = swapdate($ers[expire_day]);
		// วันเวลาดูสถานที่
		$sdate_place = swapdate($ers[sdate_place]);
		$edate_place = swapdate($ers[edate_place]);
		//echo $edate_place;
		$stime_place_arr = explode(":",$ers[stime_place]);
		$etime_place_arr = explode(":",$ers[etime_place]);
		//วันเวลาชื้อเอกสาร
		$pur_doc_d1 = swapdate($ers[pur_doc_d1]);
		$pur_doc_d2 = swapdate($ers[pur_doc_d2]);
		$stime_doc_arr = explode(":",$ers[stime_doc]);
		$etime_doc_arr = explode(":",$ers[etime_doc]);
		// วันเวลายื่นซอง
		$pur_offer_d1 = swapdate($ers[pur_offer_d1]);
		$pur_offer_d2 = swapdate($ers[pur_offer_d2]);
		$stime_offer_arr = explode(":",$ers[stime_offer]);
		$etime_offer_arr = explode(":",$ers[etime_offer]);
		
		$pur_close_d = swapdate($ers[pur_close_d]);	
		$stime_close_arr = explode(":",$ers[stime_close]);	
		$etime_close_arr = explode(":",$ers[etime_close]);	
	}

}
?><img src="../../images/profile_plus.gif" border="0" alt="เพิ่ม" align="absmiddle"><a href="auction_add.php" style="text-decoration:none;"><font class="normal_blue">เพิ่มข้อมูล</font></a><br /> 
        <br />
        <br />
       
        <form action="<?=$PHP_SELF?>" method="post" enctype="multipart/form-data" name="post" id="post" onsubmit="return check();">
             <div class="tabbertab">
             <img src="../../images/arrow-d.gif" width="13" height="13" align="absmiddle" border="0" />&nbsp;<a href="<?=$PHP_SELF?>?action=""">รายการประกวด</a>
              <table width="80%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#eeeeee">
                <tr >
                  <td align="center"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                      <tr bgcolor="#C1E2F8" class="normal_blue">
                        <td width="5%"  align="center" valign="top">ลำดับ</td>
                        <td width="24%"  align="center" valign="top" bgcolor="#C1E2F8">&nbsp;หน่วยงาน</td>
                        <td width="31%"  align="left" valign="top">&nbsp;&nbsp;&nbsp;&nbsp;
                          รายละเอียด</td>
                        <td   width="12%"align="center" valign="top"><div align="left">
                         ประเภท
                        </div></td>
                        <td width="9%"  align="center" ></td>
                        <td width="7%"  align="center">
                        <td width="5%"  align="center">&nbsp;</td>
                        <td width="3%"  align="center" >&nbsp;</td>
                        <td width="3%"  align="center">&nbsp;</td>
                        <td width="1%"  align="center">&nbsp;</td>
                      </tr>
                      <?
//$epage=$epage-$rsx[curr_auction_order];
// Sticky
if($action==""){
$sql = mysql_query("select count(*) as curr_auction_order from `auction` ") or die("Query line " . __LINE__ . " Error<hr>".mysql_error()); 
$rsx = mysql_fetch_assoc($sql);
$epage=$epage-$rsx[curr_auction_order];
 $sql = "select * from `auction` ";	
$result = mysql_query($sql)or die("Query line " . __LINE__ . " error<hr>".mysql_error());
while($rs = mysql_fetch_assoc($result)){	
	$bgcolor = "#F9C77B";
	$ij= $ij + 1;
	$sql1 = mysql_query("select detail from `auction_type` where id = '$rs[type]' ")or die("Query line " . __LINE__ . " error<hr>".mysql_error());
	$rs1 = mysql_fetch_assoc($sql1);
	$edit = "<a href='auction_edit.php?id=$rs[id]'\" style=\"text-decoration:none\"><img src=\"../../images/b_edit.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"แก้ไข\">></a>";
	$del = "<a href='?action=del&id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\" onClick=\"if(confirm('ท่านต้องการที่จะลบข้อมูล1 $rs[title] ใช่หรือไม่ ?')==true);return false;\"><img src=\"../../images/b_drop.png\" height=\"13\" width=\"11\" border=\"0\" align=\"absmiddle\">";
$stat="<a href='auction_chstat.php?id=$rs[id]' \"style=\"text-decoration:none\"><img src=\"../../images/hammer.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"เปลี่ยนสถานะ\"></a>";
?>
                      <?
	}  
	 $x=$ij-$rsx[curr_auction_order];
 $sql = "select * from `auction`  ";	
$result = mysql_query($sql)or die("Query line " . __LINE__ . " error<hr>".mysql_error());
while($rs = mysql_fetch_assoc($result)){	
	$bgcolor = ($bgcolor == "#f8f8f8") ? "#ffffff" : "#f8f8f8";
	$i = $i + 1;
	$sql1 = mysql_query("select detail from `auction_type` where id = '$rs[type]' ")or die("Query line " . __LINE__ . " error<hr>".mysql_error());
	$rs1 = mysql_fetch_assoc($sql1);
		$edit = "<a href='auction_edit.php?id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\"><img src=\"../../images/b_edit.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\"></a>";
	$del = "<a href='?action=del&id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\" onClick=\"conf('$rs[id]')\"><img src=\"../../images/b_drop.png\" height=\"13\" width=\"11\" border=\"0\" align=\"absmiddle\" alt=\"ลบ\">";
	$stat="<a href='auction_chstat.php?id=$rs[id]' \"style=\"text-decoration:none\"><img src=\"../../images/hammer.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"เปลี่ยนสถานะ\"></a>";
	
?>
                      <tr class="normal" bgcolor="<?=$bgcolor?>" onmouseover='mOvr(this,&quot;dbf2ae&quot;);' onmouseout='mOut(this,&quot;<?=$bgcolor?>&quot;);' >
                        <td align="center" height="20" class="normal_black"><?=$i?></td>
                        <td align="center" class="normal_blue" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><?=trimtxt($rs[depname], 25)?></td>
                        <td align="left" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><?=trimtxt($rs[detail], 25)?></td>
                        <td colspan="3" align="center" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><div align="left">&nbsp;
                                <?=trimtxt($rs1[detail], 20) ?>
                        </div>                          <!-- <a href="report_auction_pdf.php?sent_date="><img src="../../images/ico_tm_pdf.gif" width="16" height="16" border="0" alt="แสดงรายงาน pdf"></a>&nbsp; -->                        </td>
                        <td align="center"><?=$stat?></td>
                        <td align="center"><?=$edit?></td>
                        <td align="center"><?=$del?></td>
                      </tr>
                      <?
}  }
?>
                  </table></td>
                </tr>
              </table>
              <p></p>
          </div>
	  </form>
			
            <form action="<?=$PHP_SELF?>" method="post" enctype="multipart/form-data" name="post" id="post" onsubmit="return check();">
			              <a href="<?=$PHP_SELF?>?action=auction_expire">ครบกำหนดการยื่นซองประกวดราคา</a>
              <table width="80%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#eeeeee">
                <tr >
                  <td align="center">
				  <table width="100%" border="0" cellspacing="0" cellpadding="0">
                      <tr bgcolor="#C1E2F8" class="normal_blue">
                        <td width="5%"  align="center" valign="top">ลำดับ</td>
                        <td width="24%"  align="center" valign="top" bgcolor="#C1E2F8">&nbsp;หน่วยงาน</td>
                        <td width="31%"  align="left" valign="top">&nbsp;&nbsp;&nbsp;&nbsp;
                          รายละเอียด</td>
                        <td   width="12%"align="center" valign="top"><div align="left">
                                               </div></td>
                        <td width="9%"  align="center" ></td>
                        <td width="7%"  align="center"></td>
                        <td width="5%"  align="center">&nbsp;</td>
                        <td width="3%"  align="center" >&nbsp;</td>
                        <td width="3%"  align="center">&nbsp;</td>
                        <td width="1%"  align="center">&nbsp;</td>
                      </tr>
                      <?
//$epage=$epage-$rsx[curr_auction_order];
// Sticky
if ($action =="auction_expire") { 

$sql = mysql_query("select count(*) as curr_auction_order from `auction` ") or die("Query line " . __LINE__ . " Error<hr>".mysql_error()); 
$rsx = mysql_fetch_assoc($sql);
$epage=$epage-$rsx[curr_auction_order];
 $sql = "select * from `auction` ";	
$result = mysql_query($sql)or die("Query line " . __LINE__ . " error<hr>".mysql_error());
while($rs = mysql_fetch_assoc($result)){	
	$bgcolor = "#F9C77B";
	$ij= $ij + 1;
	$sql1 = mysql_query("select detail from `auction_type` where id = '$rs[type]' ")or die("Query line " . __LINE__ . " error<hr>".mysql_error());
	$rs1 = mysql_fetch_assoc($sql1);
	$edit = "<a href='auction_edit.php?id=$rs[id]'\" style=\"text-decoration:none\"><img src=\"../../images/b_edit.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"แก้ไข\">></a>";
	$del = "<a href='?action=del&id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\" onClick=\"if(confirm('ท่านต้องการที่จะลบข้อมูล1 $rs[title] ใช่หรือไม่ ?')==true);return false;\"><img src=\"../../images/b_drop.png\" height=\"13\" width=\"11\" border=\"0\" align=\"absmiddle\">";
$stat="<a href='auction_chstat.php?id=$rs[id]' \"style=\"text-decoration:none\"><img src=\"../../images/hammer.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"เปลี่ยนสถานะ\"></a>";
?>
                      <?
	}  
	 $x=$ij-$rsx[curr_auction_order];
 $sql = "select * from `auction` where auction_status='1' ";	
$result = mysql_query($sql)or die("Query line " . __LINE__ . " error<hr>".mysql_error());
while($rs = mysql_fetch_assoc($result)){	
	$bgcolor = ($bgcolor == "#f8f8f8") ? "#ffffff" : "#f8f8f8";
	$i = $i + 1;
	$sql1 = mysql_query("select detail from `auction_type` where id = '$rs[type]' ")or die("Query line " . __LINE__ . " error<hr>".mysql_error());
	$rs1 = mysql_fetch_assoc($sql1);
		$edit = "<a href='auction_edit.php?id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\"><img src=\"../../images/b_edit.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\"></a>";
	$del = "<a href='?action=del&id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\" onClick=\"conf('$rs[id]')\"><img src=\"../../images/b_drop.png\" height=\"13\" width=\"11\" border=\"0\" align=\"absmiddle\" alt=\"ลบ\">";
	$stat="<a href='auction_chstat.php?id=$rs[id]' \"style=\"text-decoration:none\"><img src=\"../../images/hammer.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"เปลี่ยนสถานะ\"></a>";
	
?>
                      <tr class="normal" bgcolor="<?=$bgcolor?>" onmouseover='mOvr(this,&quot;dbf2ae&quot;);' onmouseout='mOut(this,&quot;<?=$bgcolor?>&quot;);' >
                        <td align="center" height="20" class="normal_black"><?=$i?></td>
                        <td align="center" class="normal_blue" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><?=trimtxt($rs[depname], 25)?></td>
                        <td align="left" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><?=trimtxt($rs[detail], 25)?></td>
                        <td align="center" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><div align="left">&nbsp;
                                <?=trimtxt($rs1[detail], 20) ?>
                        </div></td>
                        <td align="center" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><!-- <a href="report_auction_pdf.php?sent_date="><img src="../../images/ico_tm_pdf.gif" width="16" height="16" border="0" alt="แสดงรายงาน pdf"></a>&nbsp; -->                        </td>
                        <td align="center" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"></td>
                        <td align="center"><?=$stat?></td>
                        <td align="center"><?=$edit?></td>
                        <td align="center"><?=$del?></td>
                      </tr>
                      <?
} }
?>
                  </table></td>
                </tr>
              </table>
              <p> </p>
              <p></p>
            </div></form>
			<form action="<?=$PHP_SELF?>" method="post" enctype="multipart/form-data" name="post" id="post" onsubmit="return check();">
            <div class="tabbertab">
			
             <a href="<?=$PHP_SELF?>?action=auction_com"> <img src="../../images/approve.gif" width="16" height="16" border="0" align="absmiddle" />&nbsp;ผ่านการพิจารณาประกวดราคา</a>
             <table width="80%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#eeeeee">
               <tr >
                 <td align="center"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                     <tr bgcolor="#C1E2F8" class="normal_blue">
                       <td width="5%"  align="center" valign="top">ลำดับ</td>
                       <td width="24%"  align="center" valign="top" bgcolor="#C1E2F8">&nbsp;หน่วยงาน</td>
                       <td width="31%"  align="left" valign="top">&nbsp;&nbsp;&nbsp;&nbsp;
                         รายละเอียด</td>
                       <td   width="12%"align="center" valign="top"><div align="left">
                           <? if($action=="auction_status_price"){echo "สถานะ";}else{echo "ประเภท";}?>
                       </div></td>
                       <td width="9%"  align="center" ><? if($action=="auction_news"){echo "ราคาที่ประมูลได้";}elseif($action=="auction_status"){echo "Expire Day";}?></td>
                       <td width="7%"  align="center"><? if($action=="auction_news"){echo "บริษัทที่ชนะประมูล";}elseif($action=="auction_status"){echo "Expire Time";}?></td>
                       <td width="5%"  align="center">&nbsp;</td>
                       <td width="3%"  align="center" >&nbsp;</td>
                       <td width="3%"  align="center">&nbsp;</td>
                       <td width="1%"  align="center">&nbsp;</td>
                     </tr>
                     <?
//$epage=$epage-$rsx[curr_auction_order];
// Sticky
if ($action =="auction_com") { 
$sql = mysql_query("select count(*) as curr_auction_order from `auction` ") or die("Query line " . __LINE__ . " Error<hr>".mysql_error()); 
$rsx = mysql_fetch_assoc($sql);
$epage=$epage-$rsx[curr_auction_order];
 $sql = "select * from `auction` where   bid_status='1'";	
$result = mysql_query($sql)or die("Query line " . __LINE__ . " error<hr>".mysql_error());
while($rs = mysql_fetch_assoc($result)){	
	$bgcolor = "#F9C77B";
	$ij= $ij + 1;
	$sql1 = mysql_query("select detail from `auction_type` where id = '$rs[type]' ")or die("Query line " . __LINE__ . " error<hr>".mysql_error());
	$rs1 = mysql_fetch_assoc($sql1);
	$edit = "<a href='auction_edit.php?id=$rs[id]'\" style=\"text-decoration:none\"><img src=\"../../images/b_edit.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"แก้ไข\">></a>";
	$del = "<a href='?action=del&id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\" onClick=\"if(confirm('ท่านต้องการที่จะลบข้อมูล1 $rs[title] ใช่หรือไม่ ?')==true);return false;\"><img src=\"../../images/b_drop.png\" height=\"13\" width=\"11\" border=\"0\" align=\"absmiddle\">";
$stat="<a href='auction_chstat.php?id=$rs[id]' \"style=\"text-decoration:none\"><img src=\"../../images/hammer.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"เปลี่ยนสถานะ\"></a>";
?>
                     <?
	}  
	 $x=$ij-$rsx[curr_auction_order];
 $sql = "select * from `auction` where bid_status='1' ";	
$result = mysql_query($sql)or die("Query line " . __LINE__ . " error<hr>".mysql_error());
while($rs = mysql_fetch_assoc($result)){	
	$bgcolor = ($bgcolor == "#f8f8f8") ? "#ffffff" : "#f8f8f8";
	$i = $i + 1;
	$sql1 = mysql_query("select detail from `auction_type` where id = '$rs[type]' ")or die("Query line " . __LINE__ . " error<hr>".mysql_error());
	$rs1 = mysql_fetch_assoc($sql1);
		$edit = "<a href='auction_edit.php?id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\"><img src=\"../../images/b_edit.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\"></a>";
	$del = "<a href='?action=del&id=$rs[id]'\"&page=$page\" style=\"text-decoration:none\" onClick=\"conf('$rs[id]')\"><img src=\"../../images/b_drop.png\" height=\"13\" width=\"11\" border=\"0\" align=\"absmiddle\" alt=\"ลบ\">";
	$stat="<a href='auction_chstat.php?id=$rs[id]' \"style=\"text-decoration:none\"><img src=\"../../images/hammer.png\" border=\"0\" height=\"13\" width=\"12\" align=\"absmiddle\" alt=\"เปลี่ยนสถานะ\"></a>";
	
?>
                     <tr class="normal" bgcolor="<?=$bgcolor?>" onmouseover='mOvr(this,&quot;dbf2ae&quot;);' onmouseout='mOut(this,&quot;<?=$bgcolor?>&quot;);' >
                       <td align="center" height="20" class="normal_black"><?=$i?></td>
                       <td align="center" class="normal_blue" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><?=trimtxt($rs[depname], 25)?></td>
                       <td align="left" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><?=trimtxt($rs[detail], 25)?></td>
                       <td align="center" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><div align="left">&nbsp;
                               <?=trimtxt($rs1[detail], 20) ?>
                       </div></td>
                       <td align="center" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"><!-- <a href="report_auction_pdf.php?sent_date="><img src="../../images/ico_tm_pdf.gif" width="16" height="16" border="0" alt="แสดงรายงาน pdf"></a>&nbsp; -->                       </td>
                       <td align="center" onclick="window.location.replace('?action=view&amp;id=<?=$rs[id]?>&amp;page=<?=$page?>')"></td>
                       <td align="center"><?=$stat?></td>
                       <td align="center"><?=$edit?></td>
                       <td align="center"><?=$del?></td>
                     </tr>
                     <?
} }
?>
                 </table></td>
               </tr>
             </table>
            </div>
			</form>   </td>
  </tr>
</table>
</body>
</html>

Anon7 - 2021