Welcome, Guest. Please Login or Register.
November 02, 2024, 09:26:31 AM
Home Help Search Log in Register
News: If you are still using YaBB SE, please consider upgrading to SMF as soon as possible.

YaBB SE Community  |  Development  |  Completed mods  |  [Beta 1.5.x] Floating Categories « previous next »
Pages: [1] Reply Ignore Print
Author Topic: [Beta 1.5.x] Floating Categories  (Read 4229 times)
Tywick
Noobie
*
Posts: 41


WWW
[Beta 1.5.x] Floating Categories
« on: June 22, 2003, 11:21:36 AM »
Reply with quote

I know I posted once before about this, however, I'm pretty sure the moderator deleted my post because he felt it redundant. BTW yes I did read Nicer categories (by Groundup) but I was unable to read a successful response in that thread. Here I give you a for sure working "floating" category hack which works much nicer than the original one I did.

View Sample* | Download

You can login via  Demo | demo

*The fixed background and the imaged border are NOT part of the hack. The "Mark messages Read" in the category also is NOT part of this hack.
« Last Edit: June 24, 2003, 09:52:33 PM by Tywick » Logged

Webby
Beta Tester
YaBB God
*****
Posts: 829


Some mistakes are too funny to make only once.

ICQ - 9814812webby@salesplaza.nl WWW
Re:Floating Categories for 1.5.x
« Reply #1 on: June 23, 2003, 03:42:33 AM »
Reply with quote

People with mods already built in, don't have a use for it, because you can't tell what you've changed in the Boardindex.php

To wite a mod, you have to follow the "rules" : explain what you EXACTLY changed in the sourcecode.
Logged

Webby of salesplaza.nl
The YaBBSE buttongenerator : Click HERE !
Tywick
Noobie
*
Posts: 41


WWW
Re:Floating Categories for 1.5.x
« Reply #2 on: June 24, 2003, 12:22:01 AM »
Reply with quote

In BoardIndex.php

<find>
         <table border="0" width="100%" cellspacing="0" cellpadding="0" class="bordercolor"><tr><td>
            <table border="0" width="100%" cellspacing="1" cellpadding="5" class="bordercolor">
               <tr>
                  <td class="titlebg" colspan="2"><b>' . $txt[20] . '</b></td>
                  <td class="titlebg" width="6%" align="center"><b>' . $txt[330] . '</b></td>
                  <td class="titlebg" width="6%" align="center"><b>' . $txt[21] . '</b></td>
                  <td class="titlebg" width="22%" align="center"><b>' . $txt[22] . '</b></td>
               </tr>';
</find>

<delete>
               <tr>
                  <td class="titlebg" colspan="2"><b>' . $txt[20] . '</b></td>
                  <td class="titlebg" width="6%" align="center"><b>' . $txt[330] . '</b></td>
                  <td class="titlebg" width="6%" align="center"><b>' . $txt[21] . '</b></td>
                  <td class="titlebg" width="22%" align="center"><b>' . $txt[22] . '</b></td>
               </tr>';
</delete>




<find>
      {
   $curcat=$row_board['ID_CAT'];
   echo "<tr> <td colspan=\"5\" class=\"catbg\" height=\"18\">\n";
   echo "<a name=\"$row_board[ID_CAT \"><b>$row_board[catName]</b></a></td>\n</tr>\n";
}
</find>

<replace>

{
   $BoardCount=-1;
   $curcat=$row_board['ID_CAT'];
   $FloatCounting = mysql_query(" SELECT DISTINCT ID_BOARD FROM {$db_prefix}boards WHERE ID_CAT='{$curcat}';");
   $FloatCount = mysql_num_rows($FloatCounting);

         echo '<tr> <td border="0" width="100%"><table border="0" width="100%" cellspacing="1" cellpadding="5" class="bordercolor">';
         echo "<tr> <td colspan=\"5\" class=\"catbg\" height=\"18\">\n";
         echo "<a name=\"$row_board[ID_CAT]\"><b>$row_board[catName]</b></a></td>\n</tr>\n";
         echo '<tr> <td colspan="2" height="18" class="titlebg"><table cellspacing="0" cellpadding="0" border="0" align="left" width="10%" class="F_Name_Offset"><tr><td> </td></tr></table><b>' . $txt[20] . '</b></td> <td class="titlebg" width="6%" align="center"><b>' . $txt[330] . '</b></td> <td class="titlebg" width="6%" align="center"><b>' . $txt[21] . '</b></td> <td class="titlebg" width="22%" align="center"><b>' . $txt[22] . '</b></td> </tr>';
}
</replace>




<find>
                     <font size="1">
                        ' . $latestPostTime . '<br />
                        ' . $txt['yse88'] . ' ' . $latestPostSubject . '<br />
                        ' . $txt[525] . ' ' . $latestPostName . '
                     </font>
                         </td>
                   </tr>
</find>

<replace>
                     <font size="1">
                        ' . $latestPostTime . '<br />
                        ' . $txt['yse88'] . ' ' . $latestPostSubject . '<br />
                        ' . $txt[525] . ' ' . $latestPostName . '
                     </font>';
               
$FloatBoardCount++;
if ($FloatBoardCount == $FloatCount) {
   $FloatBoardCount = 0;
   echo "</td></tr></table></td></tr>";
         echo '<tr><td height="20" bgcolor="" class="Float_Amount"></td></tr>';
} else {
echo "</td></tr>";
}
</replace>




<find>

   if ($username != 'Guest' )
   {
      echo '
               <tr>
                  <td class="titlebg" colspan="6" align="center">
                     <table cellpadding="0" border="0" cellspacing="0" width="100%">
                        <tr>
                           <td align="left">
                              ' . $img['new_some'] . '  
                              ' . $img['new_none'] . '</td>
                           <td align="right">
                              <font size="1"> ';
      if ($showmarkread == 1)
         echo " <a href=\"$scripturl?action=markallasread\">$img[markallread]</a>";
      echo '
                              </font>
                           </td>
                        </tr>
                     </table>
                  </td>
               </tr>';
   }
</find>

<replace>

   if ($username != 'Guest' )
   {
      echo '
               <tr>
                  <td><table cellpadding="0" border="0" cellspacing="1" width="100%" class="bordercolor"><tr>
                  <td class="titlebg" colspan="6" align="center">
                     <table cellpadding="5" border="0" cellspacing="1" width="100%">
                        <tr>
                           <td align="left">
                              ' . $img['new_some'] . '  
                              ' . $img['new_none'] . '</td>
                           <td align="right">
                              <font size="1"> ';
      if ($showmarkread == 1)
         echo " <a href=\"$scripturl?action=markallasread\">$img[markallread]</a>";
      echo '
                              </font>
                           </td>
                        </tr>
                     </table>
                  </td>
               </tr></table></td>
               </tr>';
   }
</replace>
« Last Edit: June 24, 2003, 04:46:58 AM by Tywick » Logged

james1979
Noobie
*
Posts: 14


I'm a llama!

Re:[Beta 1.5.x] Floating Categories
« Reply #3 on: June 24, 2003, 09:13:15 PM »
Reply with quote

Why would you want this?  Looks kinda silly...
Logged
Tywick
Noobie
*
Posts: 41


WWW
Re:[Beta 1.5.x] Floating Categories
« Reply #4 on: June 24, 2003, 09:47:31 PM »
Reply with quote

I admit that the current border I have looks "silly" but as I pointed out

Quote*The fixed background and the imaged border are NOT part of the hack.

that is NOT what your board would look like with the hack. Also even if you did an imaged border you could easily use your own images and overwrite the current ones so long as you use the proper names.

The Categories being seperated is the main focus of this hack.

Keep in mind this board was created soley for testing purposes. I do my best to point out what is and isn't part of the hack.  The hack actually looks more like http://test.msnug.com/yabbse_130 but because that's using version 1.3.0 (and also the fact I just put it up last night) I initially excluded it from this thread.
« Last Edit: June 25, 2003, 08:20:49 PM by Tywick » Logged

Webby
Beta Tester
YaBB God
*****
Posts: 829


Some mistakes are too funny to make only once.

ICQ - 9814812webby@salesplaza.nl WWW
Re:[Beta 1.5.x] Floating Categories
« Reply #5 on: June 25, 2003, 01:24:44 PM »
Reply with quote

What happens when you have the collapsable categories mod built in ?

You get floating collapsable categories ;) ?

(this is really a serious question you know....)
Logged

Webby of salesplaza.nl
The YaBBSE buttongenerator : Click HERE !
Tywick
Noobie
*
Posts: 41


WWW
Re:[Beta 1.5.x] Floating Categories
« Reply #6 on: June 25, 2003, 06:50:35 PM »
Reply with quote

After looking at http://www.teambg.net/forum/?c=all&cattog=X it appears they only float when expanded. However, I'm not exactly sure how that person modified his/her board. I do know that s/he achieves floating the way I used to do it by adding space above the category.

With the code changes mentioned above it should only affect expanded categories because you're looking for the code that displays expanded categories.
« Last Edit: June 25, 2003, 08:16:10 PM by Tywick » Logged

Pages: [1] Reply Ignore Print 
YaBB SE Community  |  Development  |  Completed mods  |  [Beta 1.5.x] Floating Categories « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.084 seconds with 21 queries.