<?php <html> <head> <title>OEE On line</title> <style type="text/css"> <!-- .style2 {font-size: 12px} .style3 {color: #FFFFFF} .style8 {font-size: 10px; color: #000000; } .style11 {font-size: 14px} .style1 {font-family: Arial, Helvetica, sans-serif; font-size: 9px; font-weight: bold; } --> </style> </head> <body> <form name="frmSearch" method="get" action="<?=$_SERVER['SCRIPT_NAME'];?>"> <table width="599" border="1"> <tr> <th>Keyword <input name="txtKeyword" type="text" id="txtKeyword" value="<?=$_GET["txtKeyword"];?>"> <input type="submit" value="Search"></th> </tr> </table> </form> <p> <? if($_GET["txtKeyword"] != "") { $objConnect = odbc_connect("oee","","") or die("Error Connect to Database"); // Search By CustomerID $strSQL = "SELECT * FROM oee WHERE (currentdate LIKE '%".$_GET["txtKeyword"]."%' )"; $objExec = odbc_exec($objConnect, $strSQL) or die ("Error Execute [".$strSQL."]"); if($objConnect) { echo "Database Connected."; } else { echo "Database Connect Failed."; } $Num_Rows = 0; while(odbc_fetch_row($objExec))$Num_Rows++; // Count Record $Per_Page = 57; // Per Page $Page = $_GET["Page"]; if(!$_GET["Page"]) { $Page=1; } $Prev_Page = $Page-1; $Next_Page = $Page+1; $Page_Start = (($Per_Page*$Page)-$Per_Page)+1; if($Num_Rows<=$Per_Page) { $Num_Pages =1; } else if(($Num_Rows % $Per_Page)==0) { $Num_Pages =($Num_Rows/$Per_Page) ; } else { $Num_Pages =($Num_Rows/$Per_Page)+1; $Num_Pages = (int)$Num_Pages; } $Page_End = $Per_Page * $Page; ?> <table width="1001" border="1"> <tr> <th width="83" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">SO./Line No</div> </div></th> <th width="72" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Part No #</div> </div></th> <th width="53" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Lot #</div> </div></th> <th width="45" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Qty.In</div> </div></th> <th width="45" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Extra</div> </div></th> <th width="44" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">CSD</div> </div></th> <th width="123" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Quanitity per Binning</div> </div></th> <th width="53" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Temp.</div> </div></th> <th width="55" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Pressure</div> </div></th> <th width="42" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Start</div> </div></th> <th width="51" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Stop</div> </div></th> <th width="51" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">TTL Time</div> </div></th> <th width="41" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Code</div> </div></th> <th width="155" bgcolor="#003366"> <div align="center" class="style11 style19 style2 style3"> <div align="center">Note</div> </div></th> </tr> <? for($i=$Page_Start;$i<=$Page_End;$i++) { $objResult = odbc_fetch_array($objExec,$i); ?> <tr> <td><div align="center" class="style8"> <div align="center"> <?=$objResult["so"];?> </div> </div></td> <td><div align="center"><span class="style8"> <?=$objResult["PartNo"];?> </span></div></td> <td><div align="center"><span class="style8"> <?=$objResult["Lot"];?> </span></div></td> <td><div align="center" class="style8"> <div align="center"> <?=$objResult["Qty"];?> </div> </div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["Extra Units"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["CSD"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["Quanitity per Binning"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["Temp"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["Pressure"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["start"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["stop"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["value_time"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["Code"];?> </span></div></td> <td align="right"><div align="center"><span class="style8"> <?=$objResult["item"];?> </span></div></td> </tr> <? } ?> </table> ?>
เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง