Bravo List
Register
Go Back   > Bravo List > Source Code > Archived Trackers > TBDev
Reply
  #1  
Old 26th April 2010, 17:49
lovebeer's Avatar
lovebeer lovebeer is offline
Senior Member
 
Join Date: May 2009
Romania
Posts: 91
Default News Mod problem
Hi, i tried to install a news mod from tbdev.net put now the tabels from the index page are bigger
The mod is from here: [/U]http://www.tbdev.net/index.php?showt...0&hl=news&st=0

This is the code that I added in index after deleting the first one:
Code:
print("<h2>Recent news");
if (get_user_class() >= UC_ADMINISTRATOR)
 print(" - <font class=small>[<a class=altlink href=news.php><b>News page</b></a>]</font>");
print("</h2>\n");
$res = mysql_query("SELECT * FROM news WHERE ADDDATE(added, INTERVAL 45 DAY) > NOW() ORDER BY added DESC LIMIT 4") or sqlerr(__FILE__, __LINE__);
if (mysql_num_rows($res) > 0)
{
 print("<table width=100% border=1 cellspacing=0 cellpadding=10><tr><td class=text>\n<ul>");
 while($array = mysql_fetch_array($res))
 {
      $user = mysql_fetch_array(mysql_query("SELECT username FROM users WHERE id = $array[userid]")) or sqlerr();
?>
<div align=center>
 <table class=nobordermain width="80%"><tr><td>
 <table class=nobordermain width="100%">
 <tr>
 <?
 print("<td class=embedded width=100% colspan=2><b>" . gmdate("Y-m-d",strtotime($array['added'])) . " - " . $array['title'] . "</b>");
 if (get_user_class() >= UC_ADMINISTRATOR) {
 print(" - <font class=small>[<a class=altlink href=news.php?action=edit&newsid=" . $array['id'] . "><b>E</b></a>]</font>");
 print(" <font class=small>[<a class=altlink href=news.php?action=delete&newsid=" . $array['id'] . "><b>D</b></a>]</font>");
 }
 print("</td>");
 ?>
 </tr>
 <tr>
 <td class=embedded width="5%"><img src="pic/news/<?=$array['cat']?>.gif" width=32 height=32></td>
 <? 
 print("<td class=embedded width=95%>" . format_comment($array['body'],0) . "</td>");
 ?>
 </tr>
 <tr>
 <td class=embedded width="100%" colspan="2">
 <?
 print("<p align=right>- <a href=userdetails.php?id=" . $array['userid'] . ">$user[username]</a></p></td>");
 ?>
 </tr>
 </table>
 </td>
 </tr>
</table>
</div>
<br><br>
<?
 }
 print("</td></tr></table>\n");
}
The index page looks like this now:

Click the image to open in full size.


The page should look like this:

Click the image to open in full size.

How can I fix this?
Thanks in advance!
__________________

Reply With Quote
Reply

Tags
mod , news , problem

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
bug with news.php wxlg1117 Yuna Scatari Edition (YSE) 1 6th July 2010 07:39
news commenting leicha Yuna Scatari Edition (YSE) 0 13th June 2010 11:52
Good News for YSE PRE6 kp380lv Community Cafe 2 29th December 2009 22:18
Torrentstrike V5 - Any news? Thor_ Torrent Strike 14 20th February 2009 16:49
News about PRE7! kp380lv Yuna Scatari Edition (YSE) 0 24th July 2008 19:48



All times are GMT +2. The time now is 20:27. vBulletin skin by ForumMonkeys. Powered by vBulletin® Version 3.8.11 Beta 3
Copyright ©2000 - 2024, vBulletin Solutions Inc.