PHP Web Host - Quality Web Hosting For All PHP Applications $35/month $250/year (Unlimited) - $25/month - 200,000 impressions - Your Ad Could be Here - Click For Details
  Login or Register
 • Home • Downloads • Your Account • Forums • 

View next topic
View previous topic


Google
 
Web RavenPHPScripts (This Site)
Post new topic   Reply to topic
Author Message
twelves
Regular
Regular


Joined: Aug 22, 2003
Posts: 84

PostPosted: Thu Mar 25, 2004 8:07 am Reply with quote Back to top

How can I add three small URL Links to appear just above the Top of this block? I want to add the Search Module Link and a link to my Mp3 Section.

Or how can I add 3 URL links to the Site Info Block that you have?





Code:
<?php

########################################################################
# PHP-Nuke Block: $ThemeSel Center Forum Block v.2                     #
# Made for PHP-Nuke 6.5 and up                                         #
#                                                                      #
# Made by mikem http://www.nukecops.com                                #
# This block is made only to match the $ThemeSel Theme pack            #
########################################################################
# 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. =)                          #
# Modified for the Nukecops.com Google Tap files.  Fully Tapped!       #
######################################################################## 

if (eregi("block-Recent_Forum_Posts.php",$PHP_SELF)) {
    Header("Location: index.php");
    die();
}

// echo "<LINK REL=\"StyleSheet\" HREF=\"themes/$ThemeSel/forums/forums.css\" TYPE=\"text/css\">\n\n\n";
       
global $prefix, $dbi, $sitename, $admin, $bgcolor1, $bgcolor2, $bgcolor3;

$HideViewReadOnly = 1;
$ThemeSel = get_theme();
$Last_New_Topics  = 10;
$show = "  <tr>
    <td height=\"28\" colspan=\"6\" align=\"center\" class=\"catbottom\" background=\"themes/$ThemeSel/forums/images/cellpic1.gif\">&nbsp;</td>
  </tr>
</table></td>
        </tr>
      </table></td>
  </tr>
</table>";

$Count_Topics = 0;
$Topic_Buffer = "";
$result = sql_query( "SELECT t.topic_id, f.forum_name, f.forum_id, t.topic_last_post_id, t.topic_title, t.topic_poster, t.topic_views, t.topic_replies, t.topic_moved_id FROM ".$prefix."_bbtopics t, ".$prefix."_bbforums f where t.forum_id=f.forum_id ORDER BY topic_last_post_id DESC", $dbi );
while( list( $topic_id, $forum_name, $forum_id, $topic_last_post_id, $topic_title, $topic_poster, $topic_views, $topic_replies, $topic_moved_id ) = sql_fetch_row( $result, $dbi ) )

{
   $skip_display = 0;
   if( $HideViewReadOnly == 1 )
   {
      $result1 = sql_query( "SELECT auth_view, auth_read FROM ".$prefix."_bbforums where forum_id = '$forum_id'", $dbi );
      list( $auth_view, $auth_read ) = sql_fetch_row( $result1, $dbi );
      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 = sql_query("SELECT username, user_id FROM ".$prefix."_users where user_id='$topic_poster'", $dbi);
list($username, $user_id)=sql_fetch_row($result2, $dbi);
$avtor=$username;
$sifra=$user_id;

$result3 = sql_query("SELECT poster_id, FROM_UNIXTIME(post_time,'%m/%d/%Y at %H:%i') as post_time FROM ".$prefix."_bbposts where post_id='$topic_last_post_id'", $dbi);
list($poster_id, $post_time)=sql_fetch_row($result3, $dbi);

$result4 = sql_query("SELECT username, user_id FROM ".$prefix."_users where user_id='$poster_id'", $dbi);
list($username, $user_id)=sql_fetch_row($result4, $dbi);

                              $viewlast .="  <tr>
    <td background=\"themes/$ThemeSel/forums/images/bk-v.jpg\" height=\"34\" nowrap bgcolor=\"$bgcolor3\" class=\"row1\"><img src=\"themes/$ThemeSel/forums/images/folder_new.gif\" border=\"0\" /></td>
    <td background=\"themes/$ThemeSel/forums/images/bk-v.jpg\" width=\"100%\" bgcolor=\"$bgcolor3\" class=\"row1\">&nbsp;$forum_name<br>&nbsp;&nbsp;<b><a href=\"postp$topic_last_post_id.html#$topic_last_post_id\">$topic_title</b></a></td>
    <td background=\"themes/$ThemeSel/forums/images/bk-w.jpg\" align=\"center\" bgcolor=\"$bgcolor1\" class=\"row2\">$topic_replies</td>
    <td background=\"themes/$ThemeSel/forums/images/bk-v.jpg\" align=\"center\" bgcolor=\"$bgcolor3\" class=\"row3\"><a href=\"forums.html&file=profile&mode=viewprofile&u=$sifra\">$avtor</a></td>
    <td background=\"themes/$ThemeSel/forums/images/bk-w.jpg\" align=\"center\" bgcolor=\"$bgcolor1\" class=\"row2\">$topic_views</td>
    <td background=\"themes/$ThemeSel/forums/images/bk-v.jpg\" align=\"center\" nowrap bgcolor=\"$bgcolor3\" class=\"row3\"><font size=\"-2\"><i>&nbsp;&nbsp;$post_time&nbsp;</i></font><br>
    <a href=\"forums.html&file=profile&mode=viewprofile&u=$user_id\">$username</a>&nbsp;<a href=\"postp$topic_last_post_id.html#$topic_last_post_id\"><img src=\"themes/$ThemeSel/forums/images/icon_minipost_new.gif\" border=\"0\" alt=\"Last Post\"></a></td>
    </tr>";
}
   
   if( $Last_New_Topics == $Count_Topics ) { break 1; }

}

    $content .= "<table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"1\">
  <tr>
    <td><table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"1\">
        <tr>
          <td bgcolor=\"$bgcolor2\"><table width=\"100%\" border=\"0\" cellpadding=\"2\" cellspacing=\"1\">
  <tr>
    <th height=\"28\" colspan=\"2\" align=\"center\" nowrap background=\"themes/$ThemeSel/forums/images/cellpic3.gif\"><font class=\"block-title\">Forum/Topic</font></th>
    <th width=\"50\" align=\"center\" nowrap background=\"themes/$ThemeSel/forums/images/cellpic3.gif\"><font class=\"block-title\">&nbsp;Replies&nbsp;</font></th>
    <th width=\"100\" align=\"center\" nowrap background=\"themes/$ThemeSel/forums/images/cellpic3.gif\"><font class=\"block-title\">&nbsp;Author&nbsp;</font></th>
    <th width=\"50\" align=\"center\" nowrap background=\"themes/$ThemeSel/forums/images/cellpic3.gif\"><font class=\"block-title\">&nbsp;Views&nbsp;</font></th>
    <th align=\"center\" nowrap background=\"themes/$ThemeSel/forums/images/cellpic3.gif\"><font class=\"block-title\">&nbsp;Last Post&nbsp;</font></th>
  </tr>";
    $content .= "$viewlast";

 $content .= "$show";

?>
View user's profile Send private message Visit poster's website
Raven
Site Admin/Owner


Joined: Aug 27, 2002
Posts: 16987
Location: Kansas

PostPosted: Thu Mar 25, 2004 8:27 am Reply with quote Back to top

"Feed a man a fish and you feed him for a day. Teach a man to fish and you feed him for a lifetime"

All blocks require the $content variable to hold all HTML output for the block. So, to add/change anything in a block you need to modify $content. Now, knowing that, find the area of html output that you want to modify and modify the $content variable at that point Wink
View user's profile Send private message Visit poster's website AIM Address Yahoo Messenger
twelves
Regular
Regular


Joined: Aug 22, 2003
Posts: 84

PostPosted: Thu Mar 25, 2004 9:44 am Reply with quote Back to top

Only registered users can see links on this board!
Get registered or login to the forums!
Thanks. It’s working. However I am still trying to get it all on one line and not 3 lines.

Thanks again, Embarassed

Ill keep cracking!

Do you have a block with HTML I can take a part to learn on?
View user's profile Send private message Visit poster's website
twelves
Regular
Regular


Joined: Aug 22, 2003
Posts: 84

PostPosted: Thu Mar 25, 2004 10:37 am Reply with quote Back to top

YES! Thanks again!
View user's profile Send private message Visit poster's website
Display posts from previous:       
Post new topic   Reply to topic

View next topic
View previous topic
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
Forums ©
 

All logos and trademarks in this site are property of their respective owner.
The comments are property of their posters, all the rest © 2002-2011 by Raven

You can syndicate our news using the file xml

CSE HTML Validator Helped Clean up This Page! [Valid RSS] valid RSS 2.0 Valid robots.txt Stop Spam Harvesters, Join Project Honey Pot

Website engines core code is © copyright by PHP-Nuke but has been heavily patched and modified by myself and others.
PHP-Nuke is a free software released under the GNU/GPL.


:: fisubice phpbb2 style by Daz :: PHP-Nuke theme by www.nukemods.com ::
:: fisubice Theme Modified by the RavenNuke™ Team ::

:: W3C CSS Compliance Validation :: W3C HTML 4.01 Transitional Compliance Validation ::

zerosum