[Openfirst-cvscommit] sidebars sidebar.php,1.1.1.1,1.2
Brought to you by:
xtimg
From: <xt...@us...> - 2003-08-23 20:26:39
|
Update of /cvsroot/openfirst/sidebars In directory sc8-pr-cvs1:/tmp/cvs-serv13510 Modified Files: sidebar.php Log Message: Replace mysql functions with new database functions, allowing multiple database types to be used easily. Index: sidebar.php =================================================================== RCS file: /cvsroot/openfirst/sidebars/sidebar.php,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** sidebar.php 14 Aug 2003 02:38:52 -0000 1.1.1.1 --- sidebar.php 23 Aug 2003 20:26:36 -0000 1.2 *************** *** 77,92 **** <?php if ($sidebar == "GUESTBOOK") { ! $qu = mysql_query("SELECT guest, date FROM ofirst_guestbook ORDER BY guest LIMIT 5;"); ! while($q = mysql_fetch_object($qu)) { echo("<sub><strong><a href='/guestbook/' target='_content'>$q->guest</a></strong><br>$q->date</sub><br>"); } } elseif ($sidebar == "NEWS") { ! $qu = mysql_query("SELECT title, poster, date FROM ofirst_news ORDER BY ID desc LIMIT 5;"); ! while($q = mysql_fetch_object($qu)) { echo("<sub><strong><a href='$home$basepath/news' target='_content' >$q->title</a></strong> - $q->poster<br>$q->date</sub><br>"); } } elseif ($sidebar == "MANUAL") { ! $qu = mysql_query("SELECT document, title FROM ofirst_manual GROUP BY document;"); ! while($q = mysql_fetch_object($qu)) { echo("<sub><a href='$home$basepath/manual' target='_content'>$q->document</a> - $q->title</sub><br>"); } --- 77,92 ---- <?php if ($sidebar == "GUESTBOOK") { ! $qu = ofirst_dbquery("SELECT guest, date FROM ofirst_guestbook ORDER BY guest LIMIT 5;"); ! while($q = ofirst_dbfetch_object($qu)) { echo("<sub><strong><a href='/guestbook/' target='_content'>$q->guest</a></strong><br>$q->date</sub><br>"); } } elseif ($sidebar == "NEWS") { ! $qu = ofirst_dbquery("SELECT title, poster, date FROM ofirst_news ORDER BY ID desc LIMIT 5;"); ! while($q = ofirst_dbfetch_object($qu)) { echo("<sub><strong><a href='$home$basepath/news' target='_content' >$q->title</a></strong> - $q->poster<br>$q->date</sub><br>"); } } elseif ($sidebar == "MANUAL") { ! $qu = ofirst_dbquery("SELECT document, title FROM ofirst_manual GROUP BY document;"); ! while($q = ofirst_dbfetch_object($qu)) { echo("<sub><a href='$home$basepath/manual' target='_content'>$q->document</a> - $q->title</sub><br>"); } *************** *** 98,103 **** } } elseif ($sidebar == "AWARDS") { ! $qu = mysql_query("SELECT AwardName FROM ofirst_awards;"); ! while($q = mysql_fetch_object($qu)) { echo("<sub><a href='$home$basepath/awards' target='_content'>$q->AwardName</a></sub><br>"); } --- 98,103 ---- } } elseif ($sidebar == "AWARDS") { ! $qu = ofirst_dbquery("SELECT AwardName FROM ofirst_awards;"); ! while($q = ofirst_dbfetch_object($qu)) { echo("<sub><a href='$home$basepath/awards' target='_content'>$q->AwardName</a></sub><br>"); } |