PDA

View Full Version : Category only view.........


12-31-2000, 04:18 PM
Hey Ed,
gotta a quick question for ya:
what hack does this site use?
http://www.carforums.com/forums/
as you can see, they use "category-only view",
and when you click on a category it takes you to a DIFFERENT page, NOT just expand to show that category.
Do you have this hack somewhere?
I really need it since I have almost 70 categories and almost 700 forums.

Thanks!

12-31-2000, 04:19 PM
You will be able to achieve this effect with v2.0

12-31-2000, 04:23 PM
but......
they have this effect without using 2.0 :(
isn't it pretty easy to create?
thanks

12-31-2000, 04:38 PM
v2.0 will be out anytime so just hang on longer. :)

12-31-2000, 04:40 PM
oh c'mon guys..... :D
its gonna take like 65 seconds to edit 1 file for it to do that. Or just tell me which file to edit! PLZ.

12-31-2000, 04:46 PM
I looked at that site and that feature is in the current release now. (1.1.5)

12-31-2000, 04:48 PM
oh kewl! thanx for the info :D

01-07-2001, 01:56 AM
I finally downloaded 1.1.5.
can you tell me where this option is?
thanx

01-07-2001, 11:50 AM
vBoard.co.uk,
where can I find that feature in 1.1.5?
I have desparately looking everywhere in the control panel. But can't find it.... :(

01-07-2001, 12:19 PM
Options!
Once loadded click on "Forums Home Page Options"
Then set Yes to: categoriesonly

Make sure usecategories is set to: Yes

01-07-2001, 12:25 PM
oh man!!!
thats not what i was talking about :( :D
that's available in any version, not just the 1.1.5... ;)

What I was talking about was....ok go to http://www.carforums.com/forums
you there? good :D
now click on "Acura"
once you do this, it will take you to a completely new page that ONLY lists the forums that are under "Acura".
vBulletin expands the categories to show the forums inside. This website uses a hack or something of that sort, because if you have 70 forums, it's not going to work morally to expand it and all that, the visitors will die because of the load time. :D

If you still aren't sure what I'm talking about gimme a beep:

ICQ # 83417350
AIM - tennisboy

.....and no, I REALLY SERIOUSLY can't wait 'till v 2.0 for this :)

thanks.

01-07-2001, 12:51 PM
Sorry I didn't notice that change.

I think they ripped out some code to do that and isn't a hack really.

01-07-2001, 12:54 PM
can you plz tell me which part to rip out???
that would be so awesome!
Or just which file should i tweak?
Thanks!!!

01-07-2001, 01:31 PM
Novel idea...

Set "categoriesonly" to yes.

01-07-2001, 01:48 PM
yes Mike, that is a very novel idea, but unfortunately that is not the issue, since I know that.
You're thinking what vboard.co.uk was thinking in the beginning and he said that the option is available in 1.1.5
Read the posts before these. :D
My porblem is this:
Once I switch to vB, I will have 70 categories and around 700 forums in them.
Of course I will use, category-only view.
I don't like the way vB works with categories only. If you click on a category, it will expand that category to show the forums inside, but it will still be a list of all other categories too.
for example:
http://www.vbulletin.com/forum/index.php?categoryid=2
you see that it display forum under "General" but you still see "vBulletin", "vBulletin 2.0 Development"...etc.
What I want my board to do when someone clicks on a category is to take him to a new page that ONLY lists the forums in that category, without displaying the whole list of other categories.

HERE IS EXACTLY HOW I WANT MY FORUM TO BEHAVE:
http://www.carforums.com/forums/
It uses vB. It is tweaked to just what I want.
Once you click on "Acura" for example, it takes to a page with ONLY the list of forums under "Audi".
You do not see the list of other categories.

I hope I made sense... :D

01-07-2001, 02:16 PM
mike, where did u go?

01-07-2001, 04:40 PM
Here is how to do this... In INDEX.PHP

look for

if (isset($categoryid)!=0 and $categoryid!=0) {
$categoryid = verifyid("category",$categoryid);
$selcategoryid=$categoryid;
$categoriesonly=1;
}


above that add:

$selcategoryid=0;


Then look for:

$categorys=$DB_site->query("SELECT categoryid,title,displayorder FROM category WHERE displayorder<>0 ORDER BY displayorder");


and replace with:

if ($selcategoryid==0) {
$categorys=$DB_site->query("SELECT categoryid,title,displayorder FROM category WHERE displayorder<>0 ORDER BY displayorder");
} else {
$categorys=$DB_site->query("SELECT categoryid,title,displayorder FROM category WHERE categoryid=$selcategoryid AND displayorder<>0 ORDER BY displayorder");
}


You can see this is in effect at http://sitepointforums.com just click on any category.,


[Edited by wluke on 01-07-2001 at 01:44 PM]

01-07-2001, 04:44 PM
THANKS
Wayne!!!
You da man! :D

01-09-2001, 01:10 PM
Originally posted by wluke
Here is how to do this... In INDEX.PHP

look for

if (isset($categoryid)!=0 and $categoryid!=0) {
$categoryid = verifyid("category",$categoryid);
$selcategoryid=$categoryid;
$categoriesonly=1;
}


above that add:

$selcategoryid=0;


Then look for:

$categorys=$DB_site->query("SELECT categoryid,title,displayorder FROM category WHERE displayorder<>0 ORDER BY displayorder");


and replace with:

if ($selcategoryid==0) {
$categorys=$DB_site->query("SELECT categoryid,title,displayorder FROM category WHERE displayorder<>0 ORDER BY displayorder");
} else {
$categorys=$DB_site->query("SELECT categoryid,title,displayorder FROM category WHERE categoryid=$selcategoryid AND displayorder<>0 ORDER BY displayorder");
}


You can see this is in effect at http://sitepointforums.com just click on any category.,


[Edited by wluke on 01-07-2001 at 01:44 PM] oh man.. never knew i needed this until it fell in my lap :)

01-09-2001, 01:22 PM
works perfectly on a renamed index.php to cat_index.php and just edited the categorybit template to point the cats to cat_index.php instead :)