vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   # of users in forum on forumhome (https://vborg.vbsupport.ru/showthread.php?t=38012)

Crazy Mofo 04-30-2002 02:57 AM

Quote:

Originally posted by nakkid
let's recap toghther crazy.. now, in that should do it... let us know if everything is ok.

OMG it worked woohooo i love you man :D :bunny:

TECK 04-30-2002 02:59 AM

congrats. ;)

Crazy Mofo 04-30-2002 03:01 AM

really graet hack thx :)

Erwin 04-30-2002 04:00 AM

Yeah, including guests would be a great addition... :)

inetd 04-30-2002 04:57 AM

FireFly, please post how to put number of users in forumhome near forum[title]. Please.

FWC 04-30-2002 05:25 AM

Quote:

Originally posted by inetd
FireFly, please post how to put number of users in forumhome near forum[title]. Please.
I just used this:
Code:

- <smallfont>($browsers members browsing)</smallfont>
after the </a> following the forum title in forumhome_forumbit_level2_post.

TECK 04-30-2002 07:11 AM

i noticed a little bug in the hack. if i browse a forum and i go back to the forumhome, it still shows that i'm browsing that forum... this is present here at vB.org also. try this. go to an empty forum (0 users browsing), then click on [vBulletin.org Forum >] navigation link at the top. it will still show that you are there. if you refresh the page it goes away... any way to fix this?

thanks.

PS. i still think of a issue to that LEFT JOIN for guests, that i asked earlier in that thread... but i cant index it, i get a database error...

Admin 04-30-2002 07:22 AM

That's a bug in vBulletin, not this hack.

To fix it, add a call to updateuserforum() in index.php like this:
Code:

updateuserforum(0);

eval("dooutput(\"".gettemplate('forumhome')."\");");

Of course it will only be updated next time you load the index page.

KuraFire 04-30-2002 09:13 AM

What am I doing wrong, I still get a separate query for each forum I have, but I followed FireFly's instructions only, not Neo's.... :/

66 queries on index page.. :'(

TECK 04-30-2002 12:32 PM

thanks firefly. do you think is a good idea to add the guests to the list of browsers?

Admin 04-30-2002 12:46 PM

You cannot.

Chris M 04-30-2002 04:28 PM

Hmmm...

Twould be interesting to say the least...

[high]* Chris M nods profusely...
[/high]

/me's alter-ego concurs...

:D

Satan

Crazy Mofo 04-30-2002 04:36 PM

how would one align it too the right next too the posts?

TECK 04-30-2002 05:06 PM

firefly, can i ask you to explain to me why i cannot index twice the same field (on 2 different tables) in database? i tried to add inforum to session and used also INDEX (inforum) but i get a database error.

i saw that you cannot LEFT JOIN session. let me know where i go wrong. if i have a inforum field in session, i could do a LEFT JOIN session and include also the guests that browse the specific forum (in theory?)...

i would like to understand a little more the mystery of LEFT JOINs to other tables. it's clear to me the mechanism of associating 2 tables info.. let me know if i should start a thread related to this in General Hacking Discussion. thanks.

Boofo 04-30-2002 07:15 PM

Neo,

How many places and where do I need to change the colspan from 6 to 7 to have the top bar show right after I add this hack? Thanks in advance.

Neo 04-30-2002 07:16 PM

That is a template edit inetd and I will take a look into the LEFT JOIN nakkid... I am very busy today O_O

Boofo 04-30-2002 10:29 PM

Firefly,

Where and how would you add this exactly? And could you also put it in the forumdisplay.php or wouldn't it work there?

updateuserforum(0);

eval("dooutput(\"".gettemplate('forumhome')."\");" );

Neo 04-30-2002 10:39 PM

It works well for me in forumdisplay.php.. just follow the first instructions I posted.

Boofo 04-30-2002 11:05 PM

I did follow the instructions in the file to a T. I wasn't sure if I needed to add that code to either of the files Firelfy mentioned. If I do, I have no idea where to add them or how to "call" them as he put it. (Sorry for being a newbie.) :-)

cdcopyworld 05-01-2002 03:39 AM

Quote:

Originally posted by FWC
I just used this:
Code:

- <smallfont>($browsers members browsing)</smallfont>
after the </a> following the forum title in forumhome_forumbit_level2_post.

Yep done that and it worked but how do i make the "$browsers members browsing" stay as far right as it can go like here at vb.org.

at the moment at my forum its right next to the forum name like this:
eg:
General Chat (10 members browsing)
i want it like this:
General Chat **********************(10 members browsing)


but without the *'s just a big space so it all stays to the right.
cheers

TECK 05-01-2002 03:51 AM

make a table.. in the left cell you put the title and in the right one the browsers..

FWC 05-01-2002 03:58 AM

Quote:

Originally posted by cdcopyworld


Yep done that and it worked but how do i make the "$browsers members browsing" stay as far right as it can go like here at vb.org.

In forumhome_forumbit_level2_post take the default:
Code:

<td bgcolor="{ firstaltcolor }" align="left"><a href="forumdisplay.php?s=$session[sessionhash]&forumid=$forum[forumid]">
<normalfont><b>$forum[title]</b></normalfont></a>
        <br><smallfont>$forum[description]</smallfont></td>

and change it to something like this:
Code:

<td bgcolor="{ firstaltcolor }">
<table width=100% cellspacing="0" cellpadding="0" border="0">
<tr>
<td align="left">
<a href="forumdisplay.php?s=$session[sessionhash]&forumid=$forum[forumid]"><normalfont><b>$forum[title]</b></normalfont></a></td>
<td width="35%" align="right" valign="top">
<smallfont>($browsers members browsing)</smallfont></td>
</tr>
<td colspan="2">
<smallfont>$forum[description]</smallfont>
</td>
</tr>
</table>
</td>

Don't forget to remove the spaces around firstaltcolor.

ZiRu$ 05-09-2002 02:00 AM

how can i have it like firefly has it ONLY! No New Column?

Neo 05-09-2002 02:25 AM

Look Up One Post

Orlandu 05-09-2002 04:20 AM

Well Neo, if you don't mind I have a addition to that hack. It will say "1 users" how it is, but I added a little bit and now it will say "1 user" and then "2 users" respectively.

I'll post if, but if you won't allow it then I will remove it.

Instead of add this:
PHP Code:

        global $forumbrowsers;
        
$count $forumbrowsers[$forum['forumid']];
        if (
intval($count) < 1) {
            
$count 0;
        } 

Add this for the correct term for 1 user:
PHP Code:

        global $forumbrowsers;
        
$count $forumbrowsers[$forum['forumid']];
                
$s 's';
        if (
intval($count) < 1) {
            
$count 0;
        }
        if (
intval($count) == 1) {
            
$s '';
        } 

That's in both forumdisplay.php and index.php
Then you have to change the counter to something like this:
Code:

($count user$s browsing)
in the right template.
Hope you like ;)

ZiRu$ 05-12-2002 09:04 PM

Quote:

Originally posted by neo
Look Up One Post
do i just install this.....or install the original hack and then that

Warlord 05-14-2002 05:55 AM

Ummm damn. All I get is grey boxes on the right side of my screen when I add this hack.. Can someone show me what I did wrong?

Warlord 05-14-2002 06:07 AM

Oh wow.. it worked.. kinda. I just noticed it, because it isn't how vb.org has it set up... but I did end up getting those annoying grey blocks on my page.. how do i get rid of those?

FWC 05-14-2002 06:12 AM

Quote:

Originally posted by Warlord
Oh wow.. it worked.. kinda. I just noticed it, because it isn't how vb.org has it set up... but I did end up getting those annoying grey blocks on my page.. how do i get rid of those?
You need to change forumhome_forumbit_leve1_nopost to <td colspan="7"> for one thing. Same thing with forumhome_loggedinusers.

Warlord 05-14-2002 06:30 AM

May Jesus have mercy on my soul....

I've attempted to make it look the way vb.org has it and screwed up alot of shi@t

Warlord 05-14-2002 07:07 AM

Ok, I have some of it fixed...

Question - In subforums, I added the same code as I did for the main page..
<code>
<td bgcolor="{firstaltcolor}">
<table width=100% cellspacing="0" cellpadding="0" border="0">
<tr>
<td align="left">
<a href="forumdisplay.php?s=$session[sessionhash]&forumid=$forum[forumid]"><normalfont><b>$forum[title]</b></normalfont></a></td>
<td width="35%" align="right" valign="top">
<smallfont>($browsers members browsing)</smallfont></td>
</tr>
<td colspan="2">
<smallfont>$forum[description]</smallfont>
</td>
</tr>
</table>
</td>
</code>

But the Members browsing appears exactly right after the forum description, so if the forum has no description, it is almost all the way over to the left.

Also.. none of the forums are picking up any members in them

Take a look and tell me what I'm doing wrong...

http://www.superherochat.com/vb

Orlandu 05-14-2002 12:43 PM

Did you add the code to index.php and forumdisplay.php? If you don't add that, then it won't work correctly.

Also, if you want it to not add the "s" if there is only one member, then use the code I posted ;)

concept 05-14-2002 02:33 PM

I'having a problem with my forums thing is i added all the chanegd neo supplyed but only thing is i'm getting an un finished </tr> or </td> somewhere cuz my forums is messed up ....

this is what it looked like now

my forums messed up

i get these grey unclosed tables wtf is up with this can someone tell me what to do

Warlord 05-14-2002 03:48 PM

Quote:

Originally posted by Orlandu
Did you add the code to inew.php and forumdisplay.php? If you don't add that, then it won't work correctly.

Also, if you want it to not add the "s" if there is only one member, then use the code I posted ;)

I assume you mean index.php and forumdisplay.php and yes I did add the code...

Got any idea about the second table data not aligning to the right on the first table row with the "forum title" and the "($browsers members browsing)"? It works just fine on then main page, but in the subforums, it aligns both table data's to the left, even though I've specified right.

Warlord 05-14-2002 04:03 PM

Ok, I figured out why it wasn't counting the users.. it's not $browsers, it supposed to be $count...

Now if I can just get the second table data to align to the right in the subforums...

concept 05-14-2002 04:32 PM

i looked around iin my templates and i got a friend of mine to work with me on it and we got ti it was innew posts
somewhere
ti was about the colums and stuff

Warlord 05-14-2002 10:09 PM

Anyone know why it won't align to the right on the sub-forums?

concept 05-15-2002 12:14 AM

is it doign that to you??? watlord?? thats what it did to me too

lifesourcerec 05-15-2002 01:03 AM

I have a very minor problem. When adding this, it added an extra column (split the category table into 2 columns instead of 1). The extra column just has a black background. How can I fix this?

Warlord 05-15-2002 01:29 AM

Quote:

Originally posted by lifesourcerec
I have a very minor problem. When adding this, it added an extra column (split the category table into 2 columns instead of 1). The extra column just has a black background. How can I fix this?
I had this same problem when I first set it up the way Neo has it... here is the solution, :)

Quote:

Originally posted by FWC
You need to change forumhome_forumbit_leve1_nopost to <td colspan="7"> for one thing. Same thing with forumhome_loggedinusers.
And yes Concept, it's being rather [better wash my mouth][better wash my mouth][better wash my mouth][better wash my mouth][better wash my mouth]y that way, isn't it? It should work. I've gone over it a million times in my head and can't figure out why it's not working.. :(


All times are GMT. The time now is 04:21 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01294 seconds
  • Memory Usage 1,830KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (6)bbcode_code_printable
  • (2)bbcode_php_printable
  • (9)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete