home *** CD-ROM | disk | FTP | other *** search
/ Practical Internet Web Designer 90 / PIWD90.iso / mac / contents / developer / tutorial_files / Pages88-89 / admin / index.php < prev   
PHP Script  |  2003-12-15  |  1KB  |  43 lines

  1. <?php
  2. //connect to the database
  3. $conn = mysql_connect("localhost","root","pwd");
  4. //choose the cms db
  5. mysql_select_db("cms", $conn);
  6. //query the database for a list of categories
  7. $result = mysql_query("SELECT catID, catName, catDesc FROM tblCat", $conn);
  8. ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  9.     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
  10.  
  11. <html>
  12. <head>
  13. <title>CMS Homepage</title>
  14. <link rel="stylesheet" type="text/css" href="../global.css" />
  15. </head>
  16.  
  17. <body>
  18. <div id="banner">
  19. <p> </p>
  20. </div>
  21. <div id="navigation">
  22. <ul class="main">
  23. <li><a href="add.php">Add Content</a></li>
  24. <li><a href="edit.php">Edit Content</a></li>
  25. <li><a href="delete.php">Delete Content</a></li>
  26. </ul>
  27. </div>
  28. <div id="content">
  29. <h1>Administration</h1>
  30.  
  31. <p>Administer your content from here.</p>
  32. <p><a href="add.php">Add Content</a><br />
  33. Add new content pages to the database.</p>
  34. <p><a href="edit.php">Edit Content</a><br />
  35. Edit pages that already exist in the database.</p>
  36. <p><a href="delete.php">Delete Content</a><br />
  37. Delete pages from the database.</p>
  38. </div>
  39. </body>
  40. </html>
  41.  
  42.  
  43.