phpBBHacks.com - Category Collapsed on Index on Default
Talk sports at SportsForums.net
StatsForums Home   RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in
FAQFAQ   SearchSearch   MemberlistMemberlist   TutorialsTutorials   ContactContact Us
Add Us:     MySpace     Facebook     StumbleUpon
Username:    Password:
Remember Me?    
Category Collapsed on Index on Default
Goto page 1, 2  Next
BlinkList
del.icio.us
Furl
linkaGoGo
reddit
Simpy
Mister Wong
Yahoo! My Web

Post new topic   Reply to topic    phpBBHacks.com Support Forums Forum Index -> Other phpBB 3 Questions and Discussion
 See a User Guidelines violation? Please contact us.
Author Message

Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12644
Location: Harbinger, NC, U.S.A.

PostPosted: June 9th 2008, 10:13 am    Post subject: Category Collapsed on Index on Default Reply with quote

Hey all,

Is there any way that you can make a category displayed as collapsed by default? Kind of like our index page here where the tutorials categories are collapsed.

I appreciate your time and help.

Thanks,

Patrick
_________________
Patrick O'Keefe - phpBBHacks.com Administrator
Author, Managing Online Forums (New Book)

Have a suggestion or a bit of feedback relating to phpBBHacks.com? Please contact me!
User Guidelines - phpBBHacks.com Awards - Featured phpBB - About Us - Supported Sites - Utilities

Vote in the phpBBHacks.com Awards 2008!
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger

~HG~
Dedicated User

Joined: 08 Nov 2003
Posts: 3192
Location: Australia

PostPosted: June 9th 2008, 12:32 pm    Post subject: Reply with quote

I am sure that there would be but finding where it is in the code is not that easy.

First thing we need to know is "which base style" are you working with and that will give us some hope of finding the existing code to look at.
_________________
~HG~

|| rodneyangell.com || My Hacks || Tutorial - Stopping Spam Bots
Back to top
View user's profile Send private message Send e-mail Visit poster's website

Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12644
Location: Harbinger, NC, U.S.A.

PostPosted: June 9th 2008, 3:11 pm    Post subject: Reply with quote

Hey ~HG~,

Thanks for the reply. Let's go with subsilver2.

Thanks,

Patrick
_________________
Patrick O'Keefe - phpBBHacks.com Administrator
Author, Managing Online Forums (New Book)

Have a suggestion or a bit of feedback relating to phpBBHacks.com? Please contact me!
User Guidelines - phpBBHacks.com Awards - Featured phpBB - About Us - Supported Sites - Utilities

Vote in the phpBBHacks.com Awards 2008!
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger

Marian
Not So New User

Joined: 08 Apr 2007
Posts: 63

PostPosted: June 10th 2008, 4:02 am    Post subject: Reply with quote

I'm not sure but maybe this is what you're looking for?

http://www.phpbb.com/community/viewtopic.php?f=70&t=699315

Although it looks like it leaves the choice which category to collapse to the user.
Back to top
View user's profile Send private message

Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12644
Location: Harbinger, NC, U.S.A.

PostPosted: June 10th 2008, 9:36 am    Post subject: Reply with quote

Hello Marian,

Thanks for that. I saw that hack, but is it possible to have categories collapsed by default?

I appreciate your help.

Thanks,

Patrick
_________________
Patrick O'Keefe - phpBBHacks.com Administrator
Author, Managing Online Forums (New Book)

Have a suggestion or a bit of feedback relating to phpBBHacks.com? Please contact me!
User Guidelines - phpBBHacks.com Awards - Featured phpBB - About Us - Supported Sites - Utilities

Vote in the phpBBHacks.com Awards 2008!
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger

~HG~
Dedicated User

Joined: 08 Nov 2003
Posts: 3192
Location: Australia

PostPosted: June 10th 2008, 12:44 pm    Post subject: Reply with quote

If you are using a default template such as Subsilver2 then you could add this mod as described.

Some templates for phpBB3 already have the collapse function included so be sure that you are aware of that.

Now from what I can see is that when you set this mod up in your ACP you set the default value to 0 (zero)

I would try it with default value at 1 to see if it works that way.

The other thing is that I realise that you do not want to collapse "all" categories either so you may have to get a rewrite done on this one so that it only collapses the categories you stipulate.
_________________
~HG~

|| rodneyangell.com || My Hacks || Tutorial - Stopping Spam Bots
Back to top
View user's profile Send private message Send e-mail Visit poster's website

Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12644
Location: Harbinger, NC, U.S.A.

PostPosted: June 10th 2008, 3:47 pm    Post subject: Reply with quote

Hey ~HG~,

Thanks for the reply and info.

Yeah, I just need those two categories to be collapsed. Hmm.

Thanks,

Patrick
_________________
Patrick O'Keefe - phpBBHacks.com Administrator
Author, Managing Online Forums (New Book)

Have a suggestion or a bit of feedback relating to phpBBHacks.com? Please contact me!
User Guidelines - phpBBHacks.com Awards - Featured phpBB - About Us - Supported Sites - Utilities

Vote in the phpBBHacks.com Awards 2008!
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger

Ptirhiik
Dedicated User

Joined: 21 Jan 2003
Posts: 1404

PostPosted: June 10th 2008, 5:29 pm    Post subject: Reply with quote

I don't think you can do this in vanilia phpBB 3. However, just make those categories forums, no posting allowed, and it will do the trick.
Back to top
View user's profile Send private message Visit poster's website

Patrick
Admin/Webmaster

Joined: 11 May 2001
Posts: 12644
Location: Harbinger, NC, U.S.A.

PostPosted: June 11th 2008, 10:42 am    Post subject: Reply with quote

Thanks for the reply, Pierre.

Would I have to show the post numbers, etc. etc. like with normal forums?

This is what I use in phpBB 2 (just a quick and dirty solution):

Code:
In index.php, find:
Code:
         if ( $viewcat == $cat_id || $viewcat == -1 )


Replace it with:
Code:
         if ( $viewcat == $cat_id || ( $viewcat == -1 && $cat_id != UNEXPANDED_CAT_ID ) )

Something like this wouldn't be possible with phpBB 3?

Thanks,

Patrick
_________________
Patrick O'Keefe - phpBBHacks.com Administrator
Author, Managing Online Forums (New Book)

Have a suggestion or a bit of feedback relating to phpBBHacks.com? Please contact me!
User Guidelines - phpBBHacks.com Awards - Featured phpBB - About Us - Supported Sites - Utilities

Vote in the phpBBHacks.com Awards 2008!
Back to top
View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger

~HG~
Dedicated User

Joined: 08 Nov 2003
Posts: 3192
Location: Australia

PostPosted: June 11th 2008, 12:43 pm    Post subject: Reply with quote

On Galahs Corner I use the mg_autumn theme by Mighty Gorgon and he use's Java Script for collapsible categories.

The default is open of course but I am thinking if you were to use the same code it would collapse all categories as default if you changed it so using JS you would need to define the categories to be collapsed as default.

I am sure this could be achieved by including a switch option in "manage forums" in the ACP

The code used is as follows (Someone might be able to elaborate on this for you)

Code:
<div><div class="tbl-h-l"><div class="tbl-h-r"><div class="tbl-h-c"><img style="padding-top:9px;padding-right:6px;float:right;cursor:pointer;" src="./styles/mg_autumn/theme/images/icon_maximize.gif" onclick="javascript:ShowHide('f_1','f_1_h','f_1');" alt="Branches" /><div class="tbl-title"><h4><a href="./viewforum.php?f=1">Gumtree Administration Branch</a></h4></div></div></div></div>
      <table class="tablebg" width="100%" cellpadding="0" cellspacing="0">
      <tr><td class="row1"><span class="gensmall">&nbsp;</span></td></tr>
      </table>
      <div class="tbl-f-l"><div class="tbl-f-r"><div class="tbl-f-c">&nbsp;</div></div></div></div>
      <br />
      </div>

      <div id="f_1">
      <script type="text/javascript">
      <!--
      tmp = 'f_1';
      if(GetCookie(tmp) == '2')
      {
         ShowHide('f_1', 'f_1_h', 'f_1');
      }
      //-->
      </script>

_________________
~HG~

|| rodneyangell.com || My Hacks || Tutorial - Stopping Spam Bots
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    phpBBHacks.com Support Forums Forum Index -> Other phpBB 3 Questions and Discussion All times are GMT - 6 Hours
Goto page 1, 2  Next
Page 1 of 2
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



Links: Big Message Boards - Free JavaScript - phpBB2 - phpbb styles - Suporte phpBB - phpBB.it - phpBB Česky - phpBB Turkiye - phpBBArabia.com - phpBB-fr.com - Romanian phpBB online community - phpBB-TW.net - phpBBservice.nl - phpBB Brasil

Network: iFroggy Network Blog - iFroggy Hosting - SportsForums.net - KarateForums.com - YanksBlog.com - PhotoshopForums.com - DeveloperCube - Managing Online Forums - ManagingCommunities.com - CommunityAdmins.com - DrGregHouse.com - Bad Boy Blog - BadBoyForums.com - SodaRatings.com - Patrick O'Keefe

< Advertising - Contact Us - Staff - User Guidelines >

Copyright © 2001-2008. iFroggy Network, phpBBHacks.com. All Rights Reserved. Privacy Policy. We Support phpBBHacks.com (of course!).
Powered by phpBB © phpBB Group. phpBB SEO. Hosted by 100MegsWebHosting. We are in no way affiliated with the phpBB Group. phpBB is copyright to the phpBB Group.