Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <html>
- <head>
- <meta charset="utf-8">
- <title>Hoctudau.com</title>
- <link rel="stylesheet" type="text/css" href=style.css>
- </head>
- <body>
- <div class="wrapper">
- <div class="header">
- <h1>Trung tâm đào tạo: hoctudau.com</h1>
- </div>
- <?php include ("functions.smart.php");
- ob_start();
- ?>
- <div class="nav">
- <ul id="nav">
- <li><a href="index.php">Trang chủ</a></li>
- <li><a href="?cat=thong-bao">Thông báo</a></li>
- <li><a href="?cat=tuyen-dung">Tuyển dụng</a></li>
- <li><a href="?cat=nhan-xet">Nhận xét</a></li>
- </ul>
- </div>
- <?php
- nav_smart(ob_get_clean(),'class="active"');
- ?>
- <div class="contents">
- <?php
- mysql_connect('localhost','u426615682_hung2','hung123');
- mysql_query("SET character_set_results=utf8");
- mysql_select_db('u426615682_bt84');
- $r=mysql_query("SELECT id,title,content,category FROM data");
- while ($row=mysql_fetch_array($r)) {
- if (@$_GET['cat']==$row['category']
- || @$_GET['p']==$row['id']
- || (@!$_GET['cat']&&@!$_GET['p'])
- ) {
- ?>
- <h3>
- <a href="?p=<?php echo $row['id'];?>">
- <?php echo $row['title'];?>
- </a>
- </h3>
- <p> <?php echo $row['content'];?></p>
- <?php
- }
- }
- ?>
- </div>
- <div class="footer">
- Copyright 2014, hoctudau.com
- </div>
- </div>
- </body>
- </html>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement