[LinksOS CVS Commit]website/include news.php,1.3,1.4
Status: Inactive
Brought to you by:
terencevs
|
From: <ke...@to...> - 2003-01-12 23:49:00
|
Update of /cvsroot/linksos/website/include In directory router-internal.tossell.net:/tmp/cvs-serv5853/include Modified Files: news.php Log Message: Title: News display mashing Changes: Added $crush and appropriate <br> , etc. Effects: News display can be chopped down to make it less wide. Maybe a better solution would be to have the first few words, then a link to the rest. a=kennyt Index: news.php =================================================================== RCS file: /cvsroot/linksos/website/include/news.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** news.php 30 Dec 2002 09:18:08 -0000 1.3 --- news.php 12 Jan 2003 23:48:51 -0000 1.4 *************** *** 1,8 **** <? class news { ! function show($num_art) { ! /* Show the num_art most recent articles. * ! * If num_art is not defined, show all articles, * ! * most recent first. Direct echo. */ $news_result = mysql_query('SELECT UNIX_TIMESTAMP(linksos_news.date),linksos_news.title,linksos_news.body,linksos_people.uid,linksos_people.fullname FROM linksos_news,linksos_people WHERE linksos_news.poster = linksos_people.uid ORDER BY linksos_news.news_id DESC'); --- 1,8 ---- <? class news { ! function show($num_art,$crush) { ! /* Show the num_art most recent articles. Compact the display * ! * if $crush is defined. If num_art is not defined, show all * ! * articles, most recent first. Direct echo. */ $news_result = mysql_query('SELECT UNIX_TIMESTAMP(linksos_news.date),linksos_news.title,linksos_news.body,linksos_people.uid,linksos_people.fullname FROM linksos_news,linksos_people WHERE linksos_news.poster = linksos_people.uid ORDER BY linksos_news.news_id DESC'); *************** *** 19,24 **** echo '<table width="100%" style="background-repeat: repeat-x; font-family: Arial; margin: 0px 0px 10px 0px; font-size: 12px; padding: 0; border: 0" cellspacing="0" cellpadding="0"><tr><td valign="top" height="12" width="50%"><b>'; echo date('l j F Y', $article[0]); ! echo ' by ' . perslink($article[3], $article[4]); ! echo '</b></td><td valign="top" style="font-weight: bold; color: #ff0000;">' . $article[1] . '</td></tr>' . '<tr><td height="7" colspan="2" background="image/line_off5.png"></td></tr>' . '<tr><td colspan="3">' . $article[2] . '</td></tr>' . --- 19,26 ---- echo '<table width="100%" style="background-repeat: repeat-x; font-family: Arial; margin: 0px 0px 10px 0px; font-size: 12px; padding: 0; border: 0" cellspacing="0" cellpadding="0"><tr><td valign="top" height="12" width="50%"><b>'; echo date('l j F Y', $article[0]); ! echo ( $crush ? '<br> ' : '' ) . ! ' by ' . perslink($article[3], $article[4]); ! echo '</b></td><td valign="' . ( $crush ? 'bottom' : 'top' ) . ! '" style="font-weight: bold; color: #ff0000;">' . $article[1] . '</td></tr>' . '<tr><td height="7" colspan="2" background="image/line_off5.png"></td></tr>' . '<tr><td colspan="3">' . $article[2] . '</td></tr>' . |