Help with Quick title mod & Forum Center block!

  Post new topicReply to topicPrintable Version
<< View previous topic View next topic >>
Share: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
#1   Help with Quick title mod & Forum Center block!
izone
CZ Newbie
izone has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: May 10, 2005
0.00 posts per day
Posts: 24
Points: 1,381
   
Hi

I use Quick Title Mod on my phpnuke site and it works fine. In frontpage of my site (not forums) I have a center block to show last topics. I wana to show text I added with this mod to title like [Fixed] etc... in front of titles of topics on this block too. How can I do this? I show u here codes for this block.

Please Teli or anybody else who can this, tel me if it is possible or not! I have spende 2 days on doing this with no result!! icon_redface.gif icon_cry.gif

Here is blocks code:


<?php

########################################################################
# PHP-Nuke Block: Advanced Center Forum Block v.3.0                      #
# Made for PHP-Nuke 6.* and the phpbb2 Nuke port only             #
# Original block made by coldblooded http://www.nukemods.com           #
# Modifieds by thainuke of ThaiNuke.net                            #
########################################################################
# This program is free software. You can redistribute it and/or modify #
# it under the terms of the GNU General Public License as published by #
# the Free Software Foundation; either version 2 of the License.       #
# If you modify this, let me know for fun. =)                          #
########################################################################

if (stristr($_SERVER['SCRIPT_NAME'], "block-Advanced_Center_Forum.php")) {
    Header("Location: index.php");
    die();
}

$HideViewReadOnly = 0;   
$Last_New_Topics  = 10;   
global $prefix, $db, $user_prefix, $sitename,$ThemeSel,$bgcolor1, $bgcolor2, $bgcolor3, $bgcolor4,$textcolor1, $textcolor2;
$folder_path = "themes/$ThemeSel/forums/";

/* Total Amount of Topics */
$result = $db->sql_query( "SELECT * FROM ".$prefix."_bbtopics" );
$Amount_Of_Topics = $db->sql_numrows( $result );

/* Total Amount of Posts */
$result = $db->sql_query( "SELECT * FROM ".$prefix."_bbposts" );
$Amount_Of_Posts = $db->sql_numrows( $result );

/* Total Amount of Topic Views */
$Amount_Of_Topic_Views = 0;
$result = $db->sql_query( "SELECT topic_views FROM ".$prefix."_bbtopics" );
while( list( $topic_views ) = $db->sql_fetchrow( $result ) )
{
   $Amount_Of_Topic_Views = $Amount_Of_Topic_Views + $topic_views;
}

/* Total Amount of Topic Replies */
$Amount_Of_Topic_Replies = 0;
$result = $db->sql_query( "SELECT topic_replies FROM ".$prefix."_bbtopics" );
while( list( $topic_replies ) = $db->sql_fetchrow( $result ) )
{
   $Amount_Of_Topic_Replies = $Amount_Of_Topic_Replies + $topic_replies;
}

/* Total Amount of Members */
$result = $db->sql_query( "SELECT * FROM ".$user_prefix."_users" );
$Amount_Of_Members = $db->sql_numrows( $result ) - 1;

if(!is_dir($folder_path))
{
   $folder_path = "modules/Forums/templates/subsilver/";
}

$show = "
   <tr><td height=\"28\" colspan=\"6\" align=\"center\" class=\"catbottom\" background=\"".$folder_path."images/cellpic1.gif\">"._Advancedcenterforumakharinersialirantraininglll."<b>$Amount_Of_Topics</b>&nbsp;|&nbsp;"._Advancedcenterforumakharinersialirantraininghh."&nbsp;<b>$Amount_Of_Posts</b>&nbsp;|&nbsp;"._Advancedcenterforumakharinersialirantrainingpp."&nbsp;<b>$Amount_Of_Topic_Views</b>&nbsp;|&nbsp;"._Advancedcenterforumakharinersialirantrainingoo."&nbsp;<b>$Amount_Of_Topic_Replies</b>&nbsp;|&nbsp;<a href=\"modules.php?name=Members_List\">"._AdvancedcenterforumListmembersirantraining."&nbsp;</a>&nbsp;<b>$Amount_Of_Members</b></td></tr><tr><td align=\"center\" colspan=\"6\">[ <a href=\"modules.php?name=Forums\">"._Advancedcenterforumforumirantraining."</a> ]&nbsp;&nbsp;&nbsp;[ <a href=\"modules.php?op=modload&name=Forums&file=search\">"._Advancedcenterforumforumsearchirantraining."</a> ]<br></td></tr></table></td></tr></table></td></tr></table>";

$Count_Topics = 0;
$Topic_Buffer = "";
$result = $db->sql_query( "SELECT topic_id, forum_id, topic_last_post_id, topic_title, topic_poster, topic_views, topic_replies, topic_moved_id FROM ".$prefix."_bbtopics ORDER BY topic_last_post_id DESC");

$viewlasttop ="
<tr><th height=\"28\" colspan=\"2\" align=\"center\" nowrap background=\"".$folder_path."images/cellpic3.gif\" class=\"row2\"><font color=\"$textcolor1\"><strong>"._Advancedcenterforummozoatirantraining."</strong></font></th>
<th align=\"center\" nowrap background=\"".$folder_path."images/cellpic3.gif\" class=\"row2\"><font color=\"$textcolor1\"><strong>&nbsp;"._Advancedcenterforumpasokhhairantraining."&nbsp;</strong></font></th>
<th align=\"center\" nowrap background=\"".$folder_path."images/cellpic3.gif\"class=\"row2\"><font color=\"$textcolor1\"><strong>&nbsp;"._Advancedcenterforumnevisandehirantraining."&nbsp;</strong></font></th>
<th align=\"center\" nowrap background=\"".$folder_path."images/cellpic3.gif\" class=\"row2\"><font color=\"$textcolor1\"><strong>&nbsp;"._Advancedcenterforumbzadidirantraining."&nbsp;</strong></font></th>
<th align=\"center\" nowrap background=\"".$folder_path."images/cellpic3.gif\" class=\"row2\"><font color=\"$textcolor1\"><strong>&nbsp;"._Advancedcenterforumakharinersialirantraining."&nbsp;</strong></font></th></tr>   
";

while( list( $topic_id, $forum_id, $topic_last_post_id, $topic_title, $topic_poster, $topic_views, $topic_replies, $topic_moved_id ) = $db->sql_fetchrow($result) )

{
   $skip_display = 0;
   if( $HideViewReadOnly == 1 )
   {
      $result2 = $db->sql_query( "SELECT auth_view, auth_read FROM ".$prefix."_bbforums where forum_id = '$forum_id'");
      list( $auth_view, $auth_read ) = $db->sql_fetchrow( $result2 );
      if( ( $auth_view != 0 ) or ( $auth_read != 0 ) ) { $skip_display = 1; }
   }
   
   if( $topic_moved_id != 0 )
   {
     // Shadow Topic !!
      $skip_display = 1;
   }
   
   if( $skip_display == 0 )
   
   {
     $Count_Topics += 1;

$result2 = $db->sql_query("SELECT username, user_id FROM ".$prefix."_users where user_id='$topic_poster'");
list($username, $user_id)=$db->sql_fetchrow($result2);
$avtor=$username;
$sifra=$user_id;

$result3 = $db->sql_query("SELECT poster_id, FROM_UNIXTIME(post_time,'%b %d, %Y at %T') as post_time FROM ".$prefix."_bbposts where post_id='$topic_last_post_id'");
list($poster_id, $post_time)=$db->sql_fetchrow($result3);

$result4 = $db->sql_query("SELECT username, user_id FROM ".$prefix."_users where user_id='$poster_id'");
list($username, $user_id)=$db->sql_fetchrow($result4);

$viewlastdetail .="
   <tr><td height=\"34\" nowrap bgcolor=\"$bgcolor1\" class=\"row1\"><img src=\"".$folder_path."images/folder_new_hot.gif\"  border=\"0\" /></td><td width=\"100%\" bgcolor=\"$bgcolor1\" class=\"row1\">&nbsp;<a href=\"modules.php?name=Forums&file=viewtopic&t=$topic_id#$topic_last_post_id\">$topic_title</a></td>
   <td align=\"center\" bgcolor=\"$bgcolor1\" class=\"row2\"><b>$topic_replies</b></td>
   <td align=\"center\" bgcolor=\"$bgcolor1\" class=\"row3\"><a href=\"modules.php?name=Forums&file=profile&mode=viewprofile&u=$sifra\">$avtor</a></td>
   <td align=\"center\" bgcolor=\"$bgcolor1\" class=\"row2\"><b>$topic_views</b></td>
   <td align=\"center\" nowrap bgcolor=\"$bgcolor1\" class=\"row3\">
   <a href=\"modules.php?name=Forums&file=profile&mode=viewprofile&u=$user_id\">$username</a>&nbsp;<a href=\"modules.php?name=Forums&file=viewtopic&p=$topic_last_post_id#$topic_last_post_id\"><img src=\"".$folder_path."images/icon_minipost_new.gif\" border=\"0\" alt=\" $post_time\"></a></td></tr>";
}
   
   if( $Last_New_Topics == $Count_Topics ) { break 1; }
   
}

    $head = "
   <table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"2\"><tr><td bgcolor=\"$bgcolor1\"><table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"1\" bgcolor=\"$bgcolor1\"><tr><td><table width=\"100%\" border=\"0\" cellpadding=\"2\" cellspacing=\"1\"><tr><td height=\"28\" colspan=\"6\" align=\"center\" class=\"row3\"><b>"._Advancedcenterforumakharinersialirantrainingooakharinersalha."</b></td></tr>
   ";
   
   

$viewcatend = "</td></tr><tr><td><br></td></tr>";

$content = "$head";
$content .= "$viewcattop";
$content .= "$viewcat";
$content .= "$viewcatend";
$content .= "$viewlasttop";
$content .= "$viewlastdetail";
$content .= "$show";

?>


Best Regards


Back to top Reply with quote
#2   
izone
CZ Newbie
izone has been a member for over 19 year's 19 Year Member
Gender: Male
Status: Offline
Joined: May 10, 2005
0.00 posts per day
Posts: 24
Points: 1,381
   
Anybody please! icon_sad.gif



Back to top Reply with quote
Display posts from previous:      
Add To: Del.icio.us  Digg  Google  Spurl  Blink  Furl  Y! MyWeb  
<< View previous topic View next topic >>
Post new topicReply to topic

Jump to 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum