<?php include_once 'header.php'; ?> <div class="white-trans-container"> <div class="search-result-panel"> <div class="floating-right"><a href="advance-search.php"><button>TÌM KIẾM NÂNG CAO</button></a></div> <h3>KẾT QUẢ TÌM KIẾM</h3><br> <?php $log = new doituong(); $userid = $_SESSION['user_id']; $ip = $_SERVER['REMOTE_ADDR']; $sql2 = "INSERT INTO log (ngayTraCuu, maNguoiDung, ip, tuKhoa, ghiChu) VALUES (NOW(), '{$userid}', '{$ip}', '{$keyword}', '10')"; $log->query($sql2); $doituong = new doituong(); $sql = "SELECT * FROM baithuoc WHERE tenBaiThuoc LIKE '%" . $keyword . "%'"; $doituong->query($sql); $data = array(); echo "<table border='1'>"; while ($row = $doituong->fetch()) { $data[] = $row; } foreach ($data as $rows) { echo "<tr><td rowspan='2' class='table-STT'>" . $rows['maBaiThuoc'] . "</td>"; echo "<td colspan='2' class='table-title'><a href='binhluanbaithuoc.php?maBaiThuoc=" . $rows['maBaiThuoc'] . "'>" . $rows['tenBaiThuoc'] . "</a></td>"; echo "</tr><tr><td class='table-detail'>" . $rows['moTaTacDung'] . "</td>"; echo "<td class='table-detail'>" . $rows['cachDung'] . "</td></tr>"; } echo "</table>"; ?> </div> </div>
<td class="value-td"><?php echo $row['email']; ?> </td> </tr> </table> <h4>Các bài đã viết:</h4> <table> <tr> <th>STT</th> <th>Tên bài viết</th> </tr> <?php $log = new doituong(); $sql2 = "SELECT * FROM baiviet WHERE maNguoiDung = {$userid}"; $log->query($sql2); $data = array(); while ($row2 = $log->fetch()) { $data[] = $row2; } $i = 0; foreach ($data as $rows2) { $i++; ?> <tr> <td class="table-STT"><?php echo $i; ?> </th> <td><?php echo "<a href='chitietbaiviet.php?maBaiViet=" . $rows2['maBaiViet'] . "'>" . $rows2['tenBaiViet'] . "</a>";
<?php include_once 'database.php'; session_start(); include_once 'doituong.php'; $doituong = new doituong(); $maBaiThuoc = $_POST['maBaiThuoc']; $noidung = $_POST['noiDung']; $user_id = $_SESSION['user_id']; $b = "INSERT INTO binhluanbaithuoc (maBaiThuoc,maNguoiDung,noiDung,ngayBinhLuan) values ({$maBaiThuoc},{$user_id},'{$noidung}',NOW())"; $doituong->query($b); header('Location: binhluanbaithuoc.php?maBaiThuoc=' . $maBaiThuoc . '#commentarea');
</td> <td> <h4>Các cây thuốc chữa bệnh thuộc nhóm này</h4> <table> <?php $sql = "SELECT * from caythuocbenh where maBenh = '" . $maBenh . "'"; $doituong->query($sql); $data = array(); while ($row = $doituong->fetch()) { $data[] = $row; } $stt = 0; foreach ($data as $rows) { $stt++; $sql2 = "SELECT * from caythuoc where maCayThuoc = '" . $rows['maCaythuoc'] . "'"; $doituong2->query($sql2); $rows2 = $doituong2->fetch(); ?> <tr> <td class="table-STT"><?php echo $stt; ?> </td> <td><?php echo "<a href='chitietcaythuoc.php?maCayThuoc=" . $rows['maCaythuoc'] . "'>" . $rows2['tenCayThuoc'] . "</a>"; ?> </td> </tr> <?php } ?>
<head> <meta charset="UTF-8"> <title>Đông Y Online | Hệ thống thông tin bài thuốc Đông Y</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="./lib/bootstrap.min.css"> <script src="./lib/jquery.min.js"></script> <script src="./lib/bootstrap.min.js"></script> <link rel="stylesheet" type="text/css" href="./css/home.css"> <?php session_start(); include_once 'doituong.php'; include_once 'database.php'; $bthuoc = new doituong(); $sql = "select * from baithuoc"; $bthuoc->query($sql); ?> </head> <body> <?php include_once 'header.php'; ?> <div class="white-trans-container"> <h2>Danh sách bài thuốc trong hệ thống</h2> <center>(click vào tên bài thuốc để đi tới chi tiết)</center> <table width="820" height="121" border="1" align="center"> <?php $data = array(); while ($row = $bthuoc->fetch()) { $data[] = $row; }
<head> <meta charset="UTF-8"> <title>Đông Y Online | Hệ thống thông tin bài thuốc Đông Y</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="./lib/bootstrap.min.css"> <script src="./lib/jquery.min.js"></script> <script src="./lib/bootstrap.min.js"></script> <link rel="stylesheet" type="text/css" href="./css/home.css"> <link rel="stylesheet" type="text/css" href="./css/benh.css"> <?php $benh = new doituong(); $sql = "select * from benh"; $benh->query($sql); $tacdung = new doituong(); $sql = "select * from tacdung"; $tacdung->query($sql); ?> </head> <body> <?php include_once 'header.php'; ?> <div class="white-trans-container"> <div class="main-container"> <div class="left-container"> <h3>DANH SÁCH CÁC BỆNH TRONG HỆ THỐNG</h3> <center>(click vào tên bệnh để xem chi tiết - Ctrl+F để tìm nhanh bằng trình duyệt)</center> <table border="1" align="center">
include_once 'database.php'; ?> <html> <head> <meta charset="UTF-8"> <title>Đông Y Online | Hệ thống thông tin bài thuốc Đông Y</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="./lib/bootstrap.min.css"> <script src="./lib/jquery.min.js"></script> <script src="./lib/bootstrap.min.js"></script> <link rel="stylesheet" type="text/css" href="./css/home.css"> <link rel="stylesheet" type="text/css" href="./css/benh.css"> <?php $baiviet = new doituong(); $sql = "select * from baiviet ORDER BY ngayViet DESC"; $baiviet->query($sql); ?> </head> <body> <?php include_once 'header.php'; ?> <div class="white-trans-container"> <div class="flow-container"> <h3>DANH MỤC BÀI VIẾT TRONG HỆ THỐNG</h3> (từ mới nhất đến cũ nhất - lia chuột để xem tóm tắt - nhấn vào từng bái viết để xem chi tiết) <div class="clear-all">.</div> <?php
?> </table> <h4>Các tác dụng của cây thuốc này</h4> <table> <?php $sql3 = "SELECT * from caythuoctacdung where maCayThuoc = '" . $maCayThuoc . "'"; $doituong->query($sql3); $data = array(); while ($row = $doituong->fetch()) { $data[] = $row; } $stt = 0; foreach ($data as $rows) { $stt++; $sql4 = "SELECT * from tacdung where maTacDung = '" . $rows['maTacDung'] . "'"; $doituong2->query($sql4); $rows2 = $doituong2->fetch(); ?> <tr> <td class="table-STT"><?php echo $stt; ?> </td> <td><?php echo $rows2['tenTacDung']; ?> </td> </tr> <?php } ?>
?> <html> <head> <meta charset="UTF-8"> <title>Đông Y Online | Hệ thống thông tin bài thuốc Đông Y</title> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="./lib/bootstrap.min.css"> <script src="./lib/jquery.min.js"></script> <script src="./lib/bootstrap.min.js"></script> <link rel="stylesheet" type="text/css" href="./css/home.css"> <?php include_once 'doituong.php'; include_once 'database.php'; $cThuoc = new doituong(); $sql = "select * from caythuoc"; $cThuoc->query($sql); ?> </head> <body> <?php include_once 'header.php'; ?> <div class="white-trans-container"> <div class="search-result-panel"> <h3>DANH SÁCH CÂY THUỐC TRONG HỆ THỐNG</h3> <center>(click vào tên cây thuốc để xem chi tiết - Ctrl+F để tìm nhanh bằng trình duyệt)</center> <table border="1" align="center"> <tr>