<!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta charset="utf-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <title>Free Bootstrap Admin Template : Binary Admin</title> <!-- BOOTSTRAP STYLES--> <link href="assets/css/bootstrap.css" rel="stylesheet" /> <!-- FONTAWESOME STYLES--> <link href="assets/css/font-awesome.css" rel="stylesheet" /> <!-- CUSTOM STYLES--> <link href="assets/css/custom.css" rel="stylesheet" /> <!-- GOOGLE FONTS--> <link href='http://fonts.googleapis.com/css?family=Open+Sans' rel='stylesheet' type='text/css' /> <link rel="stylesheet" type="text/css" href="tool/DataTables-1.10.13/media/css/dataTables.bootstrap.css"> </head> <body> <div id="wrapper"> <?php include ('menu.php'); ?> <div id="page-wrapper" > <div id="page-inner"> <div class="row"> <div class="col-md-12"> <h2>วัตถุดิบ</h2> <table id="table_id" class="display table"> <thead> <?php include ('config/config.php'); ?> <?php $strSQL = "SELECT * FROM product"; $objQuery = mysql_query($strSQL,$conn) or die ("Error Query [".$strSQL."]"); ?> <th>รหัสสินค้า</th> <th>รายละเอียดสินค้า</th> </thead> <?php while($objResult = mysql_fetch_array($objQuery)) { ?> <tbody> <td><?php echo $objResult["pro_id"];?></td> <td><?php echo $objResult["pro_name"];?></td> </tbody> <?php } ?> </table> <?php mysql_close($conn); ?> </div> </div> <!-- /. ROW --> <hr /> </div> <script src="assets/js/jquery-3.1.0.min.js"></script> <script src="assets/js/bootstrap.min.js"></script> <script type="text/javascript" src="tool/DataTables-1.10.13/media/js/jquery.dataTables.js"></script> <script type="text/javascript" src="tool/DataTables-1.10.13/media/js/dataTables.bootstrap.js"></script> <script type="text/javascript" src="assets/js/app.js"></script> <script src="assets/js/jquery.metisMenu.js"></script> <script src="assets/js/custom.js"></script> </body> </html>
$(function () { $('#table_id').dataTable({ "bPaginate": true, "bLengthChange": true, "bFilter": true, "bSort": false, //ไม่ให้มันเรียงอัตโนมัติ "bInfo": true, "bAutoWidth": false }); });
เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง