View Full Version : Flashchat: Who is chatting
Paul M
12-17-2004, 10:00 PM
This modification is no longer available or supported.
This is a simple ForumHome display of who is currently using your Flashchat.
Version 2.20 is for use with Flashchat 4.1.x - however, it may work with older versions of Flashchat if set-up correctly.
The main features of Version 2.xx are ;
1. It displays the list on Forum Home with the "Users online" display.
2. The list view is collapsable, so you just see the number.
3. Users who should display as coloured or bold etc should be displayed correctly. (based on the display usergroup)
4. If you 'hover' over a username it will show the room they are chatting in.
5. If the chat is empty, a simple "no one is chatting" message is displayed.
Note: This will not display the names of any bots in the chat, due to the strange way that flashchat stores this information.
With help from Cyricx a CPMS module is located in this post (https://vborg.vbsupport.ru/showpost.php?p=606662). (Version 2.20 only, unsupported - use at your own risk).
TwinsX2Dad
12-18-2004, 12:57 PM
Perfect and took about 15 seconds (after getting to the files).
Thanks, Paul!
Install clicked!
ryuuchida
12-19-2004, 04:34 AM
Sounds great, clicks Install.
wrongful
12-19-2004, 01:15 PM
It works fine but is there any way to hide members who have chosen to be invisible?
Paul M
12-19-2004, 01:18 PM
It works fine but is there any way to hide members who have chosen to be invisible?Yes, but I deliberately didn't include it as it seemed a bit stupid TBH, you can't hide if you are in the chat.
wrongful
12-19-2004, 01:24 PM
Yes, but I deliberately didn't include it as it seemed a bit stupid TBH, you can't hide if you are in the chat.The only reason I had asked is because I have one of my usergroups hooked up to the spy feature of FlashChat, and showing that those users are in the chat really defeats the purpose of that feature. However, I understand your reasoning and I will customize it for myself since many people might not have a use for that.
Paul M
12-19-2004, 01:38 PM
The only reason I had asked is because I have one of my usergroups hooked up to the spy feature of FlashChat, and showing that those users are in the chat really defeats the purpose of that feature. However, I understand your reasoning and I will customize it for myself since many people might not have a use for that.I see, in that case it is very easy for you, just modify the WHERE clause in the SQL to this ;
WHERE user.usergroupid <> 6 AND connections.userid IS NOT NULL ORDER BY start
Change the "6" to the id of you spy usergroup.
wrongful
12-19-2004, 01:48 PM
I see, in that case it is very easy for you, just modify the WHERE clause in the SQL to this ;
Change the "6" to the id of you spy usergroup.That did the trick, thanks!
skinny
12-19-2004, 09:04 PM
Works well, however when does the username vanish from the whos chatting list, as ive been loggeed out for some times and its still there.
Mr_Bob
12-20-2004, 12:25 AM
This is perfect. I've used Flashchat for a while and could never find a whois online edit. I installed it very quickly with no problems. Great job. *clicks install*
Paul M
12-20-2004, 12:33 AM
Works well, however when does the username vanish from the whos chatting list, as ive been loggeed out for some times and its still there.When flashchat removes the user from it's database - my guess is you are not logging out properly, but just closing the browser.
reteep
12-20-2004, 11:31 AM
Where to get Flashchat?
Paul M
12-20-2004, 11:40 AM
Where to get Flashchat?http://www.tufat.com/script2.htm
just a quick question abt flashchat ( sorry to intrude on this hack thread ), but does it connect to a specified IRC channel ?
TwinsX2Dad
12-20-2004, 02:02 PM
just a quick question abt flashchat ( sorry to intrude on this hack thread ), but does it connect to a specified IRC channel ?FlashChat does not use an IRC channel. It runs fully on your server, using flash, php & MySQL to run.
For more info, click here (http://www.tufat.com/script2.htm).
IC-Games
12-21-2004, 01:54 AM
/me clicks install
etaslim
12-21-2004, 05:42 PM
great! very usefull. click install!
Hi,
I Installed thios Mod, but the User are in Chat at forumhome, because he is not in Chat.
I closed my Browser and logged out from Forum.
It?s like great, if this small Bug can fixed :)
Paul M
12-22-2004, 11:07 AM
Hi,
I Installed thios Mod, but the User are in Chat at forumhome, because he is not in Chat.
I closed my Browser and logged out from Forum.
It?s like great, if this small Bug can fixed :)Sorry, that isn't a bug - that's user error due to the way flashchat works. You must logout of flashchat before closing your browser, otherwise flashchat may not remove you from it's active connections database.
von7thal
12-22-2004, 12:56 PM
thanks
PVTRoger
12-24-2004, 08:54 PM
Nice mod, and easy to install, but after installing I entered chat, but my name doesn't appear next to the Whose in chat box. What might I be doing wrong, any ideas?
Paul M
12-25-2004, 06:59 AM
Did you refresh the display ?
PVTRoger
12-25-2004, 08:58 AM
Paul
Merry Christmas!
Yes, I refresh the display, I waited for a half and hour and refreshed the display again, I tried everything I could think of, still no name shows up.
I'm sure it something pretty simple, but I'm not a coding expert so have no clue where to start to look.
Any other ideas?
Thanks
PVT.Roger
Paul M
12-25-2004, 01:35 PM
TBH, I have no idea - there is not exactly much to go wrong.
When you login to flashchat, it adds you to its connections database, which this hack queries. Simple as that. I would guess your flashchat isn't working quite right - what is the address of your forum ?
PVTRoger
12-25-2004, 02:45 PM
Paul
Well chat itself seems to be working fine from what I can see. My forum is here (http://www.funingaming.com/forums)
Thanks for your help.
PVT.Roger
Paul M
12-25-2004, 03:51 PM
Have you put the code in index.php ?
T3MEDIA
12-25-2004, 04:45 PM
Paul
Merry Christmas!
Yes, I refresh the display, I waited for a half and hour and refreshed the display again, I tried everything I could think of, still no name shows up.
I'm sure it something pretty simple, but I'm not a coding expert so have no clue where to start to look.
Any other ideas?
Thanks
PVT.Roger
peep sprnch.com I have it in a custom box on the main vbindex page. Not only that, guests cant see in the room and it only shows members in the room for reg. users if the chat has over 10 users. freakin hot man.
nice addition.
Paul M
12-25-2004, 07:02 PM
Paul
Here's what what my index.php looks like...
<snipped>
Well it took me a few minutes to figure out your mistake, but the small snippet of code finally gave it away.
You have put the hack code in the wrong file. It goes in vB's index.php - you appear to have installed it in flashchat's index.php.
Paul M
12-25-2004, 10:47 PM
Paul
I really appreciate all your efforts in helping me figure this out. I entered the code in index.php as you just described (or I think so). Now it shows I'm in chat, even when I'm not. Yeah, Undoubtably I have done something wrong. Here's another cut and past around the area I entered it in...
See posts 11 & 19 in this thread for your answer. :)
Btw, could you please edit your posts to enclose the code in PHP tags, otherwise unregistered users can just copy it. :)
PVTRoger
12-26-2004, 09:30 AM
Paul
Thanks! That got me sorted.
:cool:
Galadrium
12-29-2004, 12:00 PM
Installed! Great mod. Thanks
cool mod!
awesome work Paul :up:
has anyone here been able to get this working with CMPS (portal system)? It wud be even cooler if i cud get the CMPS to work with this mod.
thanks
Viks
This hack does what it promises. Thanks :D
royals
01-15-2005, 04:24 AM
Do you have a screenshot? Is it much different than this?
https://vborg.vbsupport.ru/search.php?searchid=921495
Paul M
01-15-2005, 09:37 AM
Do you have a screenshot? Is it much different than this?
https://vborg.vbsupport.ru/search.php?searchid=921495That link isn't valid so I don't know - but I have attached a screenshot to the hack.
Sinzar
01-15-2005, 09:54 AM
I installed it and it seems to be working except its showing a guy in the chat that logged off hours ago.
Paul M
01-15-2005, 11:08 AM
I installed it and it seems to be working except its showing a guy in the chat that logged off hours ago.See post 19 (https://vborg.vbsupport.ru/showpost.php?p=585037).
royals
01-15-2005, 02:08 PM
That link isn't valid so I don't know - but I have attached a screenshot to the hack.
thanks!
Hexemer
01-18-2005, 08:16 PM
Works very good. Thank you! :)
Hi,
is that possible?
Print out a text.
At [date] there wohere x User in Chat. Record at [datum] with x User
Like Whois online statistik ?
Paul M
01-21-2005, 07:20 AM
You mean a count of the record number of visitors to the chat ?
If so then yes, it would be possible, but, someone would have to write it.
Hi,
can everyone write this modification?
prof3ta
01-25-2005, 09:02 PM
how to do this for vbindex???? since vbindex.php is my index.php, i have to paste the code in there somewhere but i cant find where...
Paul M
01-25-2005, 09:30 PM
Sorry, I don't use vbindex, so I really have no idea ......
trilOByte
01-26-2005, 12:14 PM
Hi Paul, nice hack..
/me clicks install
One question though, do you think it would be possible to include some kind of "else" statement for $chatters, to print "The chatroom is empty at the moment" or something, if it is empty?
I usually have a couple in there, but seeing a blank box on the occasions that it's empty looks odd.
Cheers.
T3MEDIA
01-26-2005, 12:18 PM
Hi Paul, nice hack..
* trilOByte clicks install
One question though, do you think it would be possible to include some kind of "else" statement to print "The chatroom is empty at the moment" or something, if it is empty?
I usually have a couple in there, but seeing a blank box on the occasiopns that it's empty looks odd.
Cheers.
I did that... I also have it set up that guests cant see in... and it only shows 10 memebers and up... so if its 10 and below it says join the convo blah blah blah...
PM me I will pass it on.
oldfan
01-27-2005, 03:35 AM
/me thanks you and clicks install!
Playboy69
02-01-2005, 06:38 PM
Very nice I like it and it works great. Very easy to install as well.
Is tehre a way to make it so that I can have a module on my cmps so people can see who is online that way as well
Hope so and so far ( Hit INSTALLED)
Paul M
02-01-2005, 08:01 PM
Very nice I like it and it works great. Very easy to install as well.Thank you. :)
Is tehre a way to make it so that I can have a module on my cmps so people can see who is online that way as well We don't use cpms, but based on an example created by ericgtr for another, similar, hack of mine - I may be able to have a go - I won't be able to test it though.
Joe Black
02-02-2005, 02:52 PM
Awesome, thank you! *clicks install
Paul M
02-03-2005, 12:15 AM
We don't use cpms, but based on an example created by ericgtr for another, similar, hack of mine - I may be able to have a go - I won't be able to test it though.I have made a cpms module, based on Eric's version for my "Members who have visited today" hack.
Upload the inthechat.php file to your modules directory - and then create a new template called adv_portal_chatters. Copy the contents of adv_portal_chatters.txt into this new template.
Now Create a new module
Module Title: Users in Flashchat
Module Identifier: flashchat
File to Include: inthechat.php
OR Template to Include: (leave blank)
Templates Used: adv_portal_chatters
Note: Thanks to Cyricx for helping with this module (which I have no way of testing).
Treasure Quest
02-04-2005, 02:33 PM
Great mod Installed.
Question: While I'm logged in to my forum (Vb 3.0.6) then I click on the chat to go to the chat room, I then have to log into the chat as well.
is there Any way if one is logged onto the forum that they can go straight into the chat room without logging in again?
Thanks,
Greg
Paul M
02-04-2005, 03:36 PM
Read the integration instructions
http://www.easterpig.com/demo/flashchat/integration/vbulletin.html
and look here as well ;
https://vborg.vbsupport.ru/showthread.php?s=&threadid=74613
RetroDreams
02-04-2005, 06:38 PM
When the chat room is empty, the space is empty below. How can we get it to say "The chat room is empty" or something like that?
RetroDreams
02-04-2005, 06:57 PM
Nevermind, figured it out. Put this right above or below your $chatters code in your forumhome template.
<if condition="$totalchatters == 0">
Blah blah blah
</if>
MR-2ZZ
02-05-2005, 10:34 PM
* Install good work!
sv1cec
02-07-2005, 02:01 PM
Sorry if I am hi-jacking this thread, but I have a question.
I installed FlashChat and I am bothered by the way the messages appear, without any separation between the user name and time, and the message text. I would prefer if they were in a table, so that first column shows time/username and second shows the message text.
Unfortunatelly, the coder was not very helpful, I asked where I should start changing the code, and he didn't tell me, so I spend hours looking for that.
Has anyone of you people done that? That was the sole reason I uninstalled this program.
Thanks and sorry if I spend your bandwidth for something not all of you are interested in.
Rgds
Paul M
02-07-2005, 02:45 PM
Yes, you are hijacking my topic :ermm:
FYI: You can alter the 'timeStampFormat' parameter in the config file to space the message from the time (and use a fixed width time display).
Try something like this ;
'timeStampFormat' => " H:i : ", //pattern for PHP date function
If you have any more questions then perhaps you could create a new topic in the general area.
Thanks. :)
Bounce
02-08-2005, 01:13 PM
Simple to install....less than 10 mins
Thanks Paul
yoyoyoyo
02-08-2005, 08:09 PM
Hi Paul, nice hack..
* trilOByte clicks install
One question though, do you think it would be possible to include some kind of "else" statement for $chatters, to print "The chatroom is empty at the moment" or something, if it is empty?
I usually have a couple in there, but seeing a blank box on the occasions that it's empty looks odd.
Cheers.I agree- it is a great addition to a great program, but I would also like to see it say "nobody is currently chatting" or something to that effect
yoyoyoyo
02-08-2005, 08:16 PM
I have made an attempt at a cpms module, based on Eric's version for my "Members who have visited today" hack...
As previously mentioned - I have no way of testing this to make sure it works.It works perfectly, thanks!
kizzmet
02-08-2005, 08:41 PM
This is awesome, thank you, installing it now
djjeffa
02-08-2005, 08:52 PM
thank you it works great
Paul M
02-08-2005, 09:09 PM
I agree- it is a great addition to a great program, but I would also like to see it say "nobody is currently chatting" or something to that effectNo problem - just tag these four lines onto the end of the code added in index.php ;
else
{
$chatters = "No one is currently chatting";
}
Paul M
02-08-2005, 09:11 PM
It works perfectly, thanks!Thanks for confirming the cpms module is ok. :)
yoyoyoyo
02-08-2005, 09:21 PM
No problem - just tag these four lines onto the end of the code added in index.php ;
else
{
$chatters = "No one is currently chatting";
}
thanks much!
Treasure Quest
02-09-2005, 10:40 AM
Hi Paul,
My programmer read the instructions and installed it twice but its still not looging in automatically, Anything else we could try?
www.treasurequestxlt.com/community
Thank you,
Greg
Great mod Installed.
Question: While I'm logged in to my forum (Vb 3.0.6) then I click on the chat to go to the chat room, I then have to log into the chat as well.
is there Any way if one is logged onto the forum that they can go straight into the chat room without logging in again?
Thanks,
Greg
Paul M
02-09-2005, 01:48 PM
Hi Paul,
My programmer read the instructions and installed it twice but its still not looging in automatically, Anything else we could try?
www.treasurequestxlt.com/community
Thank you,
GregNot really much I can say without seeing your set-up.
yoyoyoyo
02-09-2005, 02:04 PM
Hi Paul,
My programmer read the instructions and installed it twice but its still not looging in automatically, Anything else we could try?
www.treasurequestxlt.com/community
Thank you,
GregI was having the same problem, then I tried logging in with the same account from a different computer, with security settings that weren't set as high, and I could enter chat without logging in, so I think that may be something to do with it.
Treasure Quest
02-09-2005, 04:15 PM
Tried lowering the security setting, ddn't work.
If I send you the files would you look at them Paul?
If so which ones would you need?
Thank you,
Greg
djjeffa
02-09-2005, 05:07 PM
Tried lowering the security setting, ddn't work.
If I send you the files would you look at them Paul?
If so which ones would you need?
Thank you,
Greg
Mine do log on its own either i have to log in a second time when i go ti flashchat. At first I thougt it was me but now that I keep seeing this problem I think there is somthing were missing is it possible it has somthing to do with the upgrade? cause the instuctions were made for .03 and it seems like noone had problems intergrating it till recently wich makes me think maybe its has somthing to do with the upgrade.
If anyone could find me the the fix I would really apereciated it .
Treasure Quest
02-09-2005, 07:41 PM
Hi,
I'm running Vb 3.0.6
Is anyone having this trouble using this hack with 3.0.6?
Thanks,
Greg
Paul M
02-09-2005, 08:26 PM
Hi,
I'm running Vb 3.0.6
Is anyone having this trouble with 3.0.6?
Thanks,
GregThis hack works fine on 3.0.6 - if you are referring to anything else then please start a new thread or use an existing relevant thread - and keep this thread for support of this hack. Thanks. :)
Treasure Quest
02-09-2005, 08:41 PM
I was referring to this hack in my prior post, all the code is inserted as stated in the instructions and just wanted a little help or sugestions :)
Thanks again,
Greg
lifesourcerec
02-09-2005, 09:14 PM
I may have to ditch IRC and use this and flashchat :)
oztrack
02-11-2005, 10:17 PM
I have installed the users in flashchat and it works great. Also the hack to make it work in vbavanced main page.
I just have one problem - if i click on a displayed user when in the vb advanced main page it is linked without the /forum being there. How can i fix this??
Paul M
02-11-2005, 11:30 PM
I just have one problem - if i click on a displayed user when in the vb advanced main page it is linked without the /forum being there. How can i fix this??I don't know anything about vB Advanced so I'm not sure if I can help you - what have you done to make it work in VBA ?
Zain Jaffer
02-14-2005, 10:58 PM
Hey awesome hack, once again like everyone just stated - it took 30 seconds to install.
I have a n00b and simple question that may be of help to everyone.
Some users are in flashchat and not in the forum .... How can I add the users in the chat to "currently active users"?
Thanks guys!
Paul M
02-15-2005, 01:22 AM
It would be somewhat complicated to do that - so simple answer - you can't.
Zain Jaffer
02-15-2005, 07:30 AM
Oh ok,
I thought that ... as well as displaying it on the who is in chat part, you can also display it on the who is currently online part and prevent it from being 2 names
Well thanks anyway ... Great hacK!
PamelaE
02-16-2005, 11:05 PM
I am using VB 3.06 and I cant see anything in FORUMHOME which says <!-- end logged-in users -->
So I put it below this code:
<if condition="$show['loggedinusers']"> <!-- who's online -->
I get whos in chat and the names but its not in a table, the names are clickable, but thats it.
Now sure whats going on there
soapchat.burtonhosting.com
Paul M
02-17-2005, 11:35 AM
You have obviously either changed your forumhome template or are using a custom one - as your currently active users is at the top - which is not standard. Where do you want the chat list to appear, top or bottom of the page ?
PamelaE
02-17-2005, 03:14 PM
I would like to show it at the top. :)
Yes you are quite right, we did change it to show at the top of the page.
Thanks
Paul M
02-17-2005, 03:51 PM
Well, if you PM me a copy of your forumhome template I'll look at how it needs changing for this hack.
djjeffa
02-19-2005, 03:22 PM
I have flash chat working perfect now the only problem is some time its empty but yet it will still say there is a user in ther. any ideal how to fix?
djjeffa
02-19-2005, 03:30 PM
I have made a cpms module, based on Eric's version for my "Members who have visited today" hack.
Upload the inthechat.php file to your modules directory - and then create a new template called adv_portal_chatters. Copy the contents of adv_portal_chatters.txt into this new template.
Now Create a new module
Module Title: Users in Flashchat
Module Identifier: (leave blank)
File to Include: inthechat.php
OR Template to Include: (leave blank)
Templates Used: adv_portal_chatters
As previously mentioned - I have no way of testing this - but others have confirmed it as working.
I gave it a shoot but its not showing up I tried goin to it derrect and got Fatal error: Call to a member function on a non-object in /home/djjeffa/public_html/vb/modules/inthechat.php on line 4
I would like to get this to work thoug
EDIT: opps sorry for the double post, I ment to edit my last post lol
Paul M
02-19-2005, 06:08 PM
I have flash chat working perfect now the only problem is some time its empty but yet it will still say there is a user in ther. any ideal how to fix?See post 19 (https://vborg.vbsupport.ru/showpost.php?p=585037).
I gave it a shoot but its not showing up I tried goin to it derrect and got Fatal error: Call to a member function on a non-object in /home/djjeffa/public_html/vb/modules/inthechat.php on line 4
I would like to get this to work thougSorry, but as I said, I have no facility to test it. FYI - As far as I can see, Line 4 is the SQL query, if this fails then something in your set-up is very broken.
djjeffa
02-19-2005, 07:40 PM
See post 19 (https://vborg.vbsupport.ru/showpost.php?p=585037).
Sorry, but as I said, I have no facility to test it. FYI - As far as I can see, Line 4 is the SQL query, if this fails then something in your set-up is very broken.
thank you i gusss my sites a mess lol
frage
02-27-2005, 09:34 AM
it workes fine
best regards
frage
m0nde
03-10-2005, 02:31 AM
This is a very simple and elegant solution.
Thanks for your work, Paul!
:banana:
cartheym
03-14-2005, 10:51 AM
hi Paul
this is one gr8 hack - thank you
it installed very easily and got it working immediately with your instructions
also is works flawlessly with vBadvanced module
See it working here - www.gpcricket.com.au
Treasure Quest
03-17-2005, 09:52 PM
Hi Paul,
I have banned a member and find that he can still log in to the chat room..Is there a post or fix for this?
Thank you,
Greg
Paul M
03-18-2005, 06:45 AM
Hi Paul,
I have banned a member and find that he can still log in to the chat room..Is there a post or fix for this?
https://vborg.vbsupport.ru/showthread.php?threadid=74613 :)
ncangler
03-24-2005, 01:45 AM
I have the same problem with a user. What is the proper way for members to log out? When I leave the chat I am automatically logged out (Mac platform).
Thanks.
Sorry, that isn't a bug - that's user error due to the way flashchat works. You must logout of flashchat before closing your browser, otherwise flashchat may not remove you from it's active connections database.
xtreme-mobile
03-24-2005, 07:32 PM
works great on vb 3.0.6
clicks install
Paul M
03-26-2005, 12:37 PM
I have the same problem with a user. What is the proper way for members to log out? Using the red Circle (or X) in the top right of the flashchat screen.
acorndomains.co
03-27-2005, 12:04 AM
works really well
www.acorndomains.co.uk
I added a message when the chat rooms are empty with a link to flash chat login to encourage people to use it.
"The Chat Rooms are currently empty. Click here to enter now. Use your Acorn Domains forum username and password to gain access"
Great mod
Thanks!
ncangler
03-27-2005, 12:22 AM
I figured that was the proceedure. :> It would be nice if we could create a reminder of some kind to click that before leaving chat.
Using the red Circle (or X) in the top right of the flashchat screen.
Paul M
03-27-2005, 07:32 AM
"The Chat Rooms are currently empty. Click here to enter now. Use your Acorn Domains forum username and password to gain access"If your integration is set-up correctly then they should log in automatically (as long as they are logged into the forum).
xtreme-mobile
03-27-2005, 01:31 PM
one quick queestion (i do apoligise if this has been mentioned already)
when i go into chat it shows me in chat
but when i log out of chat im still shown to be chatting for up to about 2 hours later
any one know why?
ncangler
03-27-2005, 06:13 PM
You need to make sure that your users click on the Red exit button in the upper right corner of the FlashChat screen before leaving. That logs them out of the chat but they stay logged in to the MysQL database of the site (assuming your forum, chat, etc. are integrated in the same MySQL database. At least this is the way it works on my system.
I'd like to figure out a way to label that red button as "Exit" or "log out Chat" or something like that.
xtreme-mobile
03-27-2005, 06:14 PM
yeh sounds as if that would be a handy feature to have :)
* Mosh clicks install
Thanks again, like the hoverover feature so that you can see what room a member is in.
jd :)
m0nde
03-29-2005, 01:10 AM
I have made a cpms module, based on Eric's version for my "Members who have visited today" hack.
As previously mentioned - I have no way of testing this - but others have confirmed it as working.
It works flawlessly on my board: http://www.bostonlove.org
Nice work, Paul
Mr_Bob
03-29-2005, 05:37 AM
You need to make sure that your users click on the Red exit button in the upper right corner of the FlashChat screen before leaving. That logs them out of the chat but they stay logged in to the MysQL database of the site (assuming your forum, chat, etc. are integrated in the same MySQL database. At least this is the way it works on my system.
I'd like to figure out a way to label that red button as "Exit" or "log out Chat" or something like that.
I'm currently beta testing FlashChat 4.0, it becomes more apparent as a logout button (it now includes a mouseover X :cool: ). Also in my tests at least the staying logged in problem can be corrected if you edit your chat config file and select close window on exit as true. This will have a small pop-up come up which logs them out of chat on either logging out or closing the window. It saved me countless headaches :).
Paul M
03-29-2005, 04:36 PM
IAlso in my tests at least the staying logged in problem can be corrected if you edit your chat config file and select close window on exit as true. This will have a small pop-up come up which logs them out of chat on either logging out or closing the window. It saved me countless headaches :).Flashchat 3.9 has this, and it works fine in IE - the problem is that the pop-up is blocked by firefox unless you allow it.
wirewolf
04-11-2005, 05:23 PM
You need to make sure that your users click on the Red exit button in the upper right corner of the FlashChat screen before leaving. That logs them out of the chat but they stay logged in to the MysQL database of the site (assuming your forum, chat, etc. are integrated in the same MySQL database. At least this is the way it works on my system.
I'd like to figure out a way to label that red button as "Exit" or "log out Chat" or something like that.ncangler and all,
Go to the chat/inc/langs/en.php file , near the end of the file, around line 222, look for:
'room' => 'Room',
'welcome' => 'Welcome USER_LABEL',
'ringTheBell' => 'No Answer? Ring The Bell:',
'logOffBtn' => 'X',Edit to:
'room' => 'Room',
'welcome' => 'Welcome USER_LABEL , Note: Please use "Exit the Chat Room" Button when you want to log out of Chat',
'ringTheBell' => 'No Answer? Ring The Bell:',
'logOffBtn' => 'Exit the Chat Room',, Or what ever wording you care to use, but you get the idea. This is only the english langauge file. Of course you would have to edit all the langauge files if you are using them.
See the screen shot:
Seems to help, but I wish ther was a way to have users log out when ever they leave the Chat Room automatically.
You can try this too: in the chat/inc/config.php around line 246,
//Logout behavior
'logout' => array(
'close' => false, // if true, then FlashChat window is closed upon logoutChange to:
//Logout behavior
'logout' => array(
'close' => true, // if true, then FlashChat window is closed upon logout, The users is logged out of Chat by either hitting the "X" button, or if they close the window. If set to true, you won't get the Log In screen after logging out. The window will close and you won't still be shown in the chat room.
John
ncangler
04-11-2005, 05:38 PM
Great news! Thanks for letting us know. Any idea on release date? The CMPS hack that indicates who is in the Chat rooms is not that helpful as right now you see folks logged in that left some time ago. When it is accurate it will be very nice.
I'm currently beta testing FlashChat 4.0, it becomes more apparent as a logout button (it now includes a mouseover X :cool: ). Also in my tests at least the staying logged in problem can be corrected if you edit your chat config file and select close window on exit as true. This will have a small pop-up come up which logs them out of chat on either logging out or closing the window. It saved me countless headaches :).
ncangler
04-11-2005, 05:41 PM
I can't view your attachment for some reason (I get a "not logged in" message with a log in screen...wierd). Thanks for the code. I'll give it a try. A visible message will certainly help folks 'do the right thing'. :)
ncangler and all,
Go to the chat/inc/langs/en.php file , near the end of the file, around line 222, look for:
'room' => 'Room',
'welcome' => 'Welcome USER_LABEL',
'ringTheBell' => 'No Answer? Ring The Bell:',
'logOffBtn' => 'X',Edit to:
'room' => 'Room',
'welcome' => 'Welcome USER_LABEL , Note: Please use "Exit the Chat Room" Button when you want to log out of Chat',
'ringTheBell' => 'No Answer? Ring The Bell:',
'logOffBtn' => 'Exit the Chat Room',, Or what ever wording you care to use, but you get the idea. This is only the english langauge file. Of course you would have to edit all the langauge files if you are using them.
See the screen shot:
Seems to help, but I wish ther was a way to have users log out when ever they leave the Chat Room automatically.
John
wirewolf
04-11-2005, 05:46 PM
I can't view your attachment for some reason (I get a "not logged in" message with a log in screen...wierd). Thanks for the code. I'll give it a try. A visible message will certainly help folks 'do the right thing'. :)
We cross posted. I just added on to my post (two up) the same fix as Mr_Bob had about the config.php file . It seems to help.
One other thing. As you know in vbulletin we use session control for members in it's urls. Ex: href="forumdisplay.php?$session[sessionurl]do=markread" and in form inputs, value="$session[sessionhash]" If a member fails to "Log Out" of the forum and just closes his browser, the session control will time out his session after a time as set by the admin, IE - Time-Out for Cookie - This is the time in seconds that a user must remain inactive before any unread posts are marked read. This setting also controls how long a user will remain on Who's Online after their last activity. set to - 900 seconds (15 minutes) and the users name is then removed from the forum online list automatically. I'm just wondering if this Time out could be incorporated in to flashchat, or could a session url be added to to /site@url.com for flashchat.
Like href="chat/flashchat.php$session[sessionurl]". I'm going to give the session url a shot and see what happens.
John
ncangler
04-11-2005, 09:36 PM
Thanks so much for this John. I made the changes below but still get "Weclome ncangler" and none of the changes show up. I'm using the Chat within a CMPS page. Would that make a difference? Thanks!
ncangler and all,
Go to the chat/inc/langs/en.php file , near the end of the file, around line 222, look for:
'room' => 'Room',
'welcome' => 'Welcome USER_LABEL',
'ringTheBell' => 'No Answer? Ring The Bell:',
'logOffBtn' => 'X',Edit to:
'room' => 'Room',
'welcome' => 'Welcome USER_LABEL , Note: Please use "Exit the Chat Room" Button when you want to log out of Chat',
'ringTheBell' => 'No Answer? Ring The Bell:',
'logOffBtn' => 'Exit the Chat Room',, Or what ever wording you care to use, but you get the idea. This is only the english langauge file. Of course you would have to edit all the langauge files if you are using them.
wirewolf
04-11-2005, 10:05 PM
Yeh, I get the same. I made the changes, and they show when you first load the flashchat page, but on the second load they don't. ???
Making this change in the config file does help though:
//Logout behavior
'logout' => array(
'close' => true, // if true, then FlashChat window is closed upon logout
John
Harry72
04-16-2005, 04:19 PM
Thx Paul. Excellent work. *klicked install* :nervous:
Paul M
04-16-2005, 09:13 PM
This hack has been updated to version 2.00 - the main change is to display the user based on the their selected display usergroup (rather than always use the primary usergroup, as previous versions did). I have also added a simple message when the chat is empty. :)
MortysTW
04-17-2005, 08:00 AM
I just got my forum to go public tonight so I'm scared to go experimenting on things I know very little about. But I got an idea.
If I wanted the "Who's Chatting" line to be displayed which I believe is this tag $chatters, at the top of all my pages on the site. Couldn't I put your code that you say to install in the index.php in my global.php page? And then no matter what page I put the $chatters, it will work?
Like I said, I just went public and scared to experiment at the moment until I do a good site back up.
But I installed your hack the way its meant to be installed in under 60 seconds and I thank you very much for your work. Great mod!
Paul M
04-17-2005, 12:04 PM
If I wanted the "Who's Chatting" line to be displayed which I believe is this tag $chatters, at the top of all my pages on the site. Couldn't I put your code that you say to install in the index.php in my global.php page? And then no matter what page I put the $chatters, it will work?
Yes, this would work - just bear in mind that the code would be called on every page that every person views.
MortysTW
04-17-2005, 04:45 PM
That's basically what I want. WIth my old forum, I had up by my logo a "WHo's Online: " and a "Who's Chatting: " on each and every page. I found the moment I did that, more people became members and the chat room really started to get used alot more.
Thanks again for the hack and your help. I'll make sure to annoy you if I have problems with my global.php idea. :D
MortysTW
04-18-2005, 02:28 AM
Okay, I said I'd be back to annoy you. I can't seem to get my idea to work. I slipped the info in the global.php instead of the index.php and that part works like a champ. Info still shows up properly at the bottom of the index.php page like your hack is suppose to.
But how do I get the $chatters to work under my logo at the top of all pages.
I tried slipping it in my header and its not working. Is it not working there because global.php isn't called immedietely maybe?
Or am I suppose to do something other than just type $chatters in the html of the page? I even copied the part that is suppose to be put into the template per your instructions but dumped that info in my header instead, and none of it worked there.
I'm at a loss. Any tips?
Paul M
04-18-2005, 11:03 AM
Where in global.php have you put the code ?
MortysTW
04-18-2005, 06:48 PM
You mean it matters? hahaa Told you I'm new. I got the ideas, just none of the know-how.
I put it at the very bottom of the page, just above the
/*================================================= =====================*\
|| ################################################## ##################
|| # Downloaded: 02:42, Wed Mar 30th 2005
|| # CVS: $RCSfile: global.php,v $ - $Revision: 1.256.2.5 $
|| ################################################## ##################
\*================================================ ======================*/
?>
Paul M
04-18-2005, 08:21 PM
That's why it doesn't work then - the header has already been called by then.
Find ;
// get new private message popup
and put it just above that.
:)
MortysTW
04-18-2005, 09:37 PM
If I'm ever asked who my hero is, I'll proudly say Paul M.
Thanks buddy. Works like a champ. Now I just gotta get my "Who's Online" working at the same location and I'm good to go.
Thanks again!
Paul M
04-18-2005, 10:07 PM
Glad it worked. :) You might want to check this hack (https://vborg.vbsupport.ru/showthread.php?t=74613) as well if you are using flashchat 3.9.
I'm surprised at how many people seem to use flashchat, I never expected this to reach so many installs. :)
delilah429
04-21-2005, 04:34 PM
I did everything you said step-by-step and the second piece of the hack works beautifully, and i even see the spot for Who's Chatting
But when i modify the index.php file, i get this error:
Parse error: parse error, unexpected ',' in /home/content/a/d/m/admin032769/html/index.php on line 35
any ideas? is spacing an issue at all? i amusing notepad and not sure if maybe that is putting in some weird chars?
delilah429
04-21-2005, 04:36 PM
Not sure what you need to see of my index.php but here is the relevant portion:
// ############# Paul M - Flashchat - Who is in the chat v2.00 ###############
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic,
connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag
as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . TABLE_PREFIX . "connections as connections
LEFT JOIN " . TABLE_PREFIX . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
unset($chatters);
$totalchatters = 0;
while ($chat = $DB_site->fetch_array($chatlist))
{
$totalchatters += 1;
$roomname = "In private room";
$chat['opentag'] = $chat['opentaga'] ;
$chat['closetag'] = $chat['closetaga'] ;
if ($chat['displaygroupid'])
{
$chat['opentag'] = $chat['opentagb'] ;
$chat['closetag'] = $chat['closetagb'] ;
}
if ($chat['ispublic']) { $roomname = "In ".$chat['name']; }
$chatters .= "<a href='member.php?u=$chat[userid]' title=\"$roomname\" >";
$chatters .= $chat['opentag'].$chat['username'].$chat['closetag']."</a>, ";
}
if ($chatters)
{
$chatters = substr($chatters, 0, strlen($chatters)-2);
}
else
{
$chatters = "No one is currently using the chat";
}
// ############# End of Who is in the chat ###############
// ### LOGGED IN USERS #################################################
$activeusers = '';
if ($vboptions['displayloggedin'])
{
$datecut = TIMENOW - $vboptions['cookietimeout'];
$numbervisible = 0;
$numberregistered = 0;
$numberguest = 0;
$forumusers = $DB_site->query("
SELECT
user.username, (user.options & $_USEROPTIONS[invisible]) AS invisible, user.usergroupid,
session.userid, session.inforum, session.lastactivity,
IF(displaygroupid=0, user.usergroupid, displaygroupid) AS displaygroupid
FROM " . TABLE_PREFIX . "session AS session
LEFT JOIN " . TABLE_PREFIX . "user AS user ON(user.userid = session.userid)
WHERE session.lastactivity > $datecut
" . iif($vboptions['displayloggedin'] == 1, "ORDER BY username ASC") . "
");
if ($bbuserinfo['userid'])
{
// fakes the user being online for an initial page view of index.php
$bbuserinfo['joingroupid'] = iif($bbuserinfo['displaygroupid'], $bbuserinfo['displaygroupid'],
$bbuserinfo['usergroupid']);
$userinfos = array
(
$bbuserinfo['userid'] => array
(
'userid' => $bbuserinfo['userid'],
'username' => $bbuserinfo['username'],
'invisible' => $bbuserinfo['invisible'],
'inforum' => 0,
'lastactivity' => TIMENOW,
'usergroupid' => $bbuserinfo['usergroupid'],
'displaygroupid' => $bbuserinfo['displaygroupid'],
)
);
}
else
{
$userinfos = array();
}
$inforum = array();
while ($loggedin = $DB_site->fetch_array($forumusers))
{
$userid = $loggedin['userid'];
if (!$userid)
{ // Guest
$numberguest++;
$inforum["$loggedin[inforum]"]++;
}
else if (empty($userinfos["$userid"]) OR ($userinfos["$userid"]['lastactivity'] <
$loggedin['lastactivity']))
{
$userinfos["$userid"] = $loggedin;
}
}
foreach($userinfos AS $userid => $loggedin)
{
$numberregistered++;
if ($userid != $bbuserinfo['userid'])
{
$inforum["$loggedin[inforum]"]++;
}
$loggedin['musername'] = fetch_musername($loggedin);
if (fetch_online_status($loggedin))
{
$numbervisible++;
eval('$activeusers .= ", ' . fetch_template('forumhome_loggedinuser') . '";');
}
}
// memory saving
unset($userinfos, $loggedin);
$activeusers = substr($activeusers , 2); // get rid of initial comma
$DB_site->free_result($loggedins);
$totalonline = $numberregistered + $numberguest;
$numberinvisible = $numberregistered - $numbervisible;
Paul M
04-21-2005, 04:57 PM
Posting a section of code for all to see is not something you should be doing. Please hide all code inside code/php tags. It's also a waste of time since there are no line numbers. Also, you are not showing as having installed the hack, I will normally only provide support if you have clicked install. Thanks. :)
delilah429
04-21-2005, 05:18 PM
Sorry - i didn't know how to do the code inside php tags? for future reference, how should i do that?
Anyway, i clicked Install - sorry about that.
Anyway, line 35 references $globaltemplates = array(
so do i need to add a reference to this new template that is being called?
Paul M
04-21-2005, 05:47 PM
There is no new template associated with this hack - and line 35 is well away from the changes made by this hack. I suggest you revert to a fresh [original] copy of index.php and make the edit again.
MortysTW
04-22-2005, 01:56 AM
Also for the future, using notepad is probably about the safest thing you could use. NotePad doesn't add in junk. Word would. Just FYI.
Also, delilah429, this might sound really stupid, but you didn't by any chance remove all the code that was ABOVE the logged in users when you added the chat snippet in your index.php did you? I just found it odd you chose to include soooo much of everything below the LOGGED IN USERS but didn't include anything above the CHAT snippet in what you pasted in above.
delilah429
04-22-2005, 02:00 AM
Well I was just coming back here to say that I downloaded EditPlus to see if it was something the editor was doing and it worked PERFECTLY! so i am not sure - and no, i didn't delete what was above that line - it was silly just to show that snippet though - irrelevant, i suppose - but like i said i did the exact same thing and it worked - go figure
Love this!
Mr_Bob
04-24-2005, 02:45 AM
Is the upgraded version supposed to work with the newly released FlashChat 4.0? If so, mine is not working :D. I logged into chat and refreshed the forum homepage to find it still said no users in chat. Is this supposed to be working with 4.0?
Paul M
04-24-2005, 12:56 PM
Is the upgraded version supposed to work with the newly released FlashChat 4.0? If so, mine is not working :D. I logged into chat and refreshed the forum homepage to find it still said no users in chat. Is this supposed to be working with 4.0?The upgrade was nothing to do with any version of Flashchat, it was an alteration to take account of the displaygroupid in vB.
However, this hack works perfectly for Flashchat 4.0.0 (beta) - I have been running this version of the chat on our forum for 2/3 weeks now, so you must have made a mistake somewhere.
Mr_Bob
04-24-2005, 02:27 PM
The upgrade was nothing to do with any version of Flashchat, it was an alteration to take account of the displaygroupid in vB.
However, this hack works perfectly for Flashchat 4.0.0 (beta) - I have been running this version of the chat on our forum for 2/3 weeks now, so you must have made a mistake somewhere.
I must, however FlashChat came out of beta on the 21. It worked well when I was working with the beta, but not now. I'll post up part of my index.php file and forumhome template
}
// ############# Paul M - Flashchat - Who is in the chat v2.00 ###############
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . TABLE_PREFIX . "connections as connections
LEFT JOIN " . TABLE_PREFIX . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
unset($chatters);
$totalchatters = 0;
while ($chat = $DB_site->fetch_array($chatlist))
{
$totalchatters += 1;
$roomname = "In private room";
$chat['opentag'] = $chat['opentaga'] ;
$chat['closetag'] = $chat['closetaga'] ;
if ($chat['displaygroupid'])
{
$chat['opentag'] = $chat['opentagb'] ;
$chat['closetag'] = $chat['closetagb'] ;
}
if ($chat['ispublic']) { $roomname = "In ".$chat['name']; }
$chatters .= "<a href='member.php?u=$chat[userid]' title=\"$roomname\" >";
$chatters .= $chat['opentag'].$chat['username'].$chat['closetag']."</a>, ";
}
if ($chatters)
{
$chatters = substr($chatters, 0, strlen($chatters)-2);
}
else
{
$chatters = "No one is currently using the chat";
}
// ############# End of Who is in the chat ###############
// ### LOGGED IN USERS #################################################
$activeusers = '';
if ($vboptions['displayloggedin'])
{
$datecut = TIMENOW - $vboptions['cookietimeout'];
$numbervisible = 0;
$numberregistered = 0;
$numberguest = 0;
$forumusers = $DB_site->query("
SELECT
user.username, (user.options & $_USEROPTIONS[invisible]) AS invisible, user.usergroupid,
session.userid, session.inforum, session.lastactivity,
IF(displaygroupid=0, user.usergroupid, displaygroupid) AS displaygroupid
FROM " . TABLE_PREFIX . "session AS session
LEFT JOIN " . TABLE_PREFIX . "user AS user ON(user.userid = session.userid)
WHERE session.lastactivity > $datecut
" . iif($vboptions['displayloggedin'] == 1, "ORDER BY username ASC") . "
");
if ($bbuserinfo['userid'])
{
// fakes the user being online for an initial page view of index.php
$bbuserinfo['joingroupid'] = iif($bbuserinfo['displaygroupid'], $bbuserinfo['displaygroupid'], $bbuserinfo['usergroupid']);
$userinfos = array
(
$bbuserinfo['userid'] => array
(
'userid' => $bbuserinfo['userid'],
'username' => $bbuserinfo['username'],
'invisible' => $bbuserinfo['invisible'],
'inforum' => 0,
'lastactivity' => TIMENOW,
'usergroupid' => $bbuserinfo['usergroupid'],
'displaygroupid' => $bbuserinfo['displaygroupid'],
)
);
}
else
{
$userinfos = array();
}
$inforum = array();
while ($loggedin = $DB_site->fetch_array($forumusers))
{
$userid = $loggedin['userid'];
if (!$userid)
{ // Guest
$numberguest++;
$inforum["$loggedin[inforum]"]++;
}
else if (empty($userinfos["$userid"]) OR ($userinfos["$userid"]['lastactivity'] < $loggedin['lastactivity']))
{
$userinfos["$userid"] = $loggedin;
}
}
foreach($userinfos AS $userid => $loggedin)
{
$numberregistered++;
if ($userid != $bbuserinfo['userid'])
{
$inforum["$loggedin[inforum]"]++;
}
$loggedin['musername'] = fetch_musername($loggedin);
if (fetch_online_status($loggedin))
{
$numbervisible++;
eval('$activeusers .= ", ' . fetch_template('forumhome_loggedinuser') . '";');
}
}
// memory saving
unset($userinfos, $loggedin);
$activeusers = substr($activeusers , 2); // get rid of initial comma
$DB_site->free_result($loggedins);
$totalonline = $numberregistered + $numberguest;
$numberinvisible = $numberregistered - $numbervisible;
// ### MAX LOGGEDIN USERS ################################
$maxusers = unserialize($datastore['maxloggedin']);
if (intval($maxusers['maxonline']) <= $totalonline)
{
$maxusers['maxonline'] = $totalonline;
$maxusers['maxonlinedate'] = TIMENOW;
build_datastore('maxloggedin', serialize($maxusers));
}
$recordusers = $maxusers['maxonline'];
$recorddate = vbdate($vboptions['dateformat'], $maxusers['maxonlinedate'], true);
$recordtime = vbdate($vboptions['timeformat'], $maxusers['maxonlinedate']);
$show['loggedinusers'] = true;
}
else
{
$show['loggedinusers'] = false;
}
// ### GET FORUMS & MODERATOR iCACHES ########################
cache_ordered_forums(1);
if ($vboptions['showmoderatorcolumn'])
{
cache_moderators();
}
else
{
$imodcache = array();
$mod = array();
}
// define max depth for forums display based on $vboptions[forumhomedepth]
define('MAXFORUMDEPTH', $vboptions['forumhomedepth']);
$forumbits = construct_forum_bit($forumid);
Also here is the portion of my forumhome template:
<!-- end logged-in users -->
<!-- who's in flashchat -->
<tbody>
<tr>
<td class="thead" colspan="2">
<a style="float:$stylevar[right]" href="#top" onclick="return toggle_collapse('forumhome_chatusers')"><img id="collapseimg_forumhome_chatusers" src="$stylevar[imgdir_button]/collapse_thead$vbcollapse[collapseimg_forumhome_chatusers].gif" alt="" border="0" /></a>
Members currently in the Chat: $totalchatters
</td>
</tr>
</tbody>
<tbody id="collapseobj_forumhome_chatusers" style="$vbcollapse[collapseobj_forumhome_chatusers]">
<tr>
<td class="alt2"><img src="$stylevar[imgdir_misc]/whos_online.gif" alt="Users online today" border="0" /></td>
<td class="alt1" width="100%"><div class="smallfont">$chatters</div></td>
</tr>
</tbody>
<!-- end who's in flashchat -->
</if>
<tbody>
Hope you can help me out, this is a great hack I won't give up on without a fight :).
Paul M
04-24-2005, 03:56 PM
I must, however FlashChat came out of beta on the 21. It worked well when I was working with the beta, but not now. Hmmm. I wasn't aware that it had been released in full - I'll grab the latest version then to see if anything has changed.
Mr_Bob
04-24-2005, 04:43 PM
Hmmm. I wasn't aware that it had been released in full - I'll grab the latest version then to see if anything has changed.
Yeah, there are now two VBCMPS files. VBCMPS2 being for 3.0.7. Also, I know commen.php and many other files changed drasticly. There were also changes to the MYSQL tables. This may be the problem.
PS: Do not install the bots:), there is a bug where if you install them with a cms you will get call to undefined member errors. This is supposed to be fixed in a later release.
Paul M
04-24-2005, 10:11 PM
Well they really f**ked up from 4.0.0 beta to 4.0.1 didn't they :rolleyes: - Yes, the BOTS are a pain - I had to edit proc.php despite turning them off.
The problem with the hack seems to be down to the fact that 4.0.1 now uses it's own table prefix system with vB - as well as the vB table prefix system - and to make it worse, there is an error in the CMS2 file as well. The default prefix they use seems to be "flashchat_", but you will find it in the config.srv.php file as below ;
<?php
$GLOBALS['fc_config']['db'] = array(
'host' => 'localhost',
'user' => 'sqluser',
'pass' => 'password',
'base' => 'database',
'pref' => '',
// 'pref' => 'flashchat_',
);
?>
Try the following experimental fix and let me know how it goes.
Find this in the Hack Code ;
// ############# Paul M - Flashchat - Who is in the chat v2.00 ###############
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . TABLE_PREFIX . "connections as connections
LEFT JOIN " . TABLE_PREFIX . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
and replace it with this ;
// ############# Paul M - Flashchat - Who is in the chat v2.05 ###############
require_once('./flashchat/inc/config.srv.php');
$fcprefix = $GLOBALS['fc_config']['db']['pref'];
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . TABLE_PREFIX . $fcprefix . "connections as connections
LEFT JOIN " . TABLE_PREFIX . $fcprefix . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
:)
LEAD_WEIGHT
04-24-2005, 11:13 PM
Can this be change to work with AMF FlashChat http://www.tufat.com/ simular but different. :ermm:
I can fiddle around with it but I am not a coder but know how to play with codes a little. :nervous:
Mr_Bob
04-24-2005, 11:55 PM
Well they really f**ked up from 4.0.0 beta to 4.0.1 didn't they :rolleyes: - Yes, the BOTS are a pain - I had to edit proc.php despite turning them off.
The problem with the hack seems to be down to the fact that 4.0.1 now uses it's own table prefix system with vB - as well as the vB table prefix system - and to make it worse, there is an error in the CMS2 file as well. The default prefix they use seems to be "flashchat_", but you will find it in the config.srv.php file as below ;
<?php
$GLOBALS['fc_config']['db'] = array(
'host' => 'localhost',
'user' => 'sqluser',
'pass' => 'password',
'base' => 'database',
'pref' => '',
// 'pref' => 'flashchat_',
);
?>
Try the following experimental fix and let me know how it goes.
Find this in the Hack Code ;
// ############# Paul M - Flashchat - Who is in the chat v2.00 ###############
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . TABLE_PREFIX . "connections as connections
LEFT JOIN " . TABLE_PREFIX . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
and replace it with this ;
// ############# Paul M - Flashchat - Who is in the chat v2.05 ###############
require_once('./flashchat/inc/config.srv.php');
$fcprefix = $GLOBALS['fc_config']['db']['pref'];
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . TABLE_PREFIX . $fcprefix . "connections as connections
LEFT JOIN " . TABLE_PREFIX . $fcprefix . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
:)
Works great perfectly:)
However where it says
require_once('./flashchat/inc/config.srv.php');
Should read
require_once('./chat/inc/config.srv.php');
FlashChat 4.0.1 uses a folder called chat now instead of FlashChat. any new people that will use this hack will run into a file error if it is not changed. Either this, or it can be made a note in installation to change this variable to your directory :).
Great job Paul:)
Paul M
04-25-2005, 12:15 AM
Works great perfectly:)
However where it says
require_once('./flashchat/inc/config.srv.php');
Should read
require_once('./chat/inc/config.srv.php');
FlashChat 4.0.1 uses a folder called chat now instead of FlashChat. any new people that will use this hack will run into a file error if it is not changed. Either this, or it can be made a note in installation to change this variable to your directory :).
Great job Paul:)
Don't you just love consistancy, why do they change things just for the sake of it. :rolleyes:
I will make a note of it, people who upgrade from 3.x.x to 4.0.1 will probably retain the flashchat folder (as I did).
Mr_Bob
04-25-2005, 12:32 AM
Don't you just love consistancy, why do they change things just for the sake of it. :rolleyes:
I will make a note of it, people who upgrade from 3.x.x to 4.0.1 will probably retain the flashchat folder (as I did).
Yup, you have to love it :p
I myself just changed the folder to the name chat. I try to keep everything as it came as much as possible :). Even with these problems some of which plain acts of negligence on the coding side my members still like 4.0.1, and that's what makes them and myself happy:). *with the exception of installation, it was iKonboard all over again*
Paul M
04-25-2005, 01:06 AM
Well since it seems to work ok, I have uploaded it as Version 2.10.
NFLForums
04-25-2005, 04:30 AM
Installed times 2 so far...
I have 3 different forums...The third is on it's way soon, I have to install flashchat to it first! :)
NFLForums
04-25-2005, 04:33 AM
err wait a second...I don't think I even want to think about going up to 4.0.1 at this point -- I was already having enough issues with 3.9.6...
(man alive...I'm glad I got the 3.9.6 before it upgraded...If there are that many problems -- since they are *oh so helpful* on the flashchat forums :S)
Paul M
04-25-2005, 11:25 AM
err wait a second...I don't think I even want to think about going up to 4.0.1 at this point -- I was already having enough issues with 3.9.6...
(man alive...I'm glad I got the 3.9.6 before it upgraded...If there are that many problems -- since they are *oh so helpful* on the flashchat forums :S)Yep, I would stick with 3.9.6 unless you have the patience to sort out 4.0.1 and it's problems.
I noticed how "helpful" they are on the fc forum when I posted yesterday. I really can't understand why they have added all this "bots" crap either, I haven't come across anyone who wants to chat to a flipping robot.
Mr_Bob
04-25-2005, 07:22 PM
Yep, I would stick with 3.9.6 unless you have the patience to sort out 4.0.1 and it's problems.
I noticed how "helpful" they are on the fc forum when I posted yesterday. I really can't understand why they have added all this "bots" crap either, I haven't come across anyone who wants to chat to a flipping robot.
It was one of the most suggested features, everyone wanted FlashChat to have as much simularity bewtween good o'l IRC as possible. The bots are a nice additiopn, I just wish they waited a little longer before releasing a version where bots won't work in CMS intergration.
memobug
04-26-2005, 08:18 PM
Hi Mr. Bob,
I did get my install of 4.0.1 working with vbulletin 3.0.7 and yes the bots are silly but even that seems to be working now.
I wish I could tell you exactly what made the difference. I am using the CMS2 verison and the prefix is finally reading in as _fc_, which is what it seems to want. I have no idea why the installer wasn't pulling in the right database & prefix info, but it suddenly started finding what it needed. I am using absolute paths in the CMS2 to my install which is in /root/chat not /root/forum/chat.
The problem I am trying to resolve now is incorporating /chat/info.php output using vbulletin's phpinclude_start template. I am having problems that I didn't have with 3.9.6. I don't want to clutter the thread here - so that discussion is going on in Tufat - http://www.tufat.com/phpBB2/viewtopic.php?t=5779
at least it would be going on if the moderator there didn't want me to fill the "Code Depot" with half baked code.
I am afraid, after all that effort it is back to 3.9.6 for me!
Regards,
Matt
Hanif
05-03-2005, 03:30 PM
Paul,
I've installed this hack however I'm trying to get the User Count to work and not having much joy
my config.serve.php has those values as the ones below(of course hidden)
and I can't get the count thing to work apart from that it looks fine.
I can send you any further info as well if need be.
I'm running vb 3.07 and the Flash chat as 4.0 or above
<?php
$GLOBALS['fc_config']['db'] = array(
'host' => 'localhost',
'user' => 'sqluser',
'pass' => 'password',
'base' => 'database',
'pref' => '',
// 'pref' => 'flashchat_',
);
?>
Look forward to your help.
Kind regards,
Hanif
Paul M
05-03-2005, 04:04 PM
Did you install FC 4.0.x from scratch ? What table prefix did you choose during the installation ? (you appear to have commented out the "flashchat_" choice in your config above).
A link, and test login to your site would be useful as well. :)
Hanif
05-03-2005, 06:16 PM
Hiya Paul,
Your the man...thanks for getting in touch dude.
Link is www.muslimprofessionals.org.uk/forums
I had the vb3_fc chat for 4.0 install and prior to that I had vb3 during the old one. I can access the chat and it logs in if a user account is recognised and accepted...??? Strange
I've PMed you a login for a test account.
Kindest regards,
Hanif
Paul M
05-03-2005, 07:22 PM
I have found your problem.
In the code near the top is this ;
// ## Paul M - Flashchat - Who is in the chat v2.10 ## //
// ## Make sure the folder name defined below is the correct name of your flashchat installation folder ## //
$fcfolder = 'flashchat';
You haven't edited this variable to "chat" rather than "flashchat" - So the hack is still looking at your old flashchat, which I discovered is still installed. If I log into the old version it shows me on the forumhome. :)
Hanif
05-03-2005, 09:12 PM
Hi Paul many thanks for replying back mate,
but I've checked the code again
and I do have the variable as
$fcfolder = 'chat';
I've pm'd you a snipped of the index.php and the config.srv.php
Kindest regards,
Hanif Rehman
p.s. once again thanks for going to the trouble for looking at this
Paul M
05-03-2005, 10:16 PM
Okay, I need ftp access to investigate this properly - there is a mis-match somewhere. I have dropped you a PM.
Paul M
05-04-2005, 09:21 PM
Well I'm not sure where you have gone - but I have uploaded a slightly changed version (v2.16) - I think this may cure your problem.
Acers
05-05-2005, 11:14 AM
a bit of a problem(actually a big one)
I am using the latest 4.02 version of flashchat.
And after doing this(also used the integration hack https://vborg.vbsupport.ru/showthread.php?t=74613&highlight=flashchat) I am facing a queer problem.
The hack is working for me but not for others. I can see who is in chat and all from all browsers but for all others, they can't even open the forums page(by all others i mean normal users, supermods etc) They are getting either ascii gibberish in opera or in FF they just get a blank page for forum home. All other forum pages load properly.
the actual view source code they see is
<html><body></body></html> in ff
And as soon as i remove the code in hack from index.php it starts to work normally for all.
I have rechecked the code and where i am putting it and its all correct. Even tried moving it around in index.php and still same probs.
what could be wrong?
the funny part is that its working for me... but not for anyone else :S
diettalk
05-05-2005, 12:55 PM
flashchat v4.04 is out...
Paul M
05-05-2005, 04:10 PM
what could be wrong?
the funny part is that its working for me... but not for anyone else :SSorry, I have no idea. I can't think of any way you could get this. What version are you using ?
flashchat v4.04 is out...Yep - like 4.0.3 it's just a couple of very minor changes (to the bots code this time).
Acers
05-06-2005, 03:28 PM
4.02 version...
i have no idea myself.
It works for me and not for anyone else. All get ascii chars.
Maybe some other hack is interfering...
Paul M
05-06-2005, 03:41 PM
4.02 version...No, which version of the Hack :) (2.16 is the latest).
It works for me and not for anyone else. All get ascii chars.
Maybe some other hack is interfering...Unlikely, your site seems fine to me (assuming it's the one in your profile) do you have it installed atm ?
Acers
05-06-2005, 05:24 PM
was using 2.15 but used the new one now(changed folder name to chat) but same problem.
I am putting a screenshot of what members are getting as soon as i do the file edit.
(I am btw getting what you should get. The who is chatting is showing for me)
And yes the site is www.techenclave.com
and this is the source of forumhome people see once i put the edit of the hack in index.php
http://img193.echo.cx/my.php?image=screenshot1wm.jpg
Btw the time you see this post, the hack is not installed. I have reverted back to original index.php file or else the whole lot of members were after me :)
Paul M
05-06-2005, 06:15 PM
Are you doing the Forumhome template edit as well - I can't see that either ?
If so, which combination causes your problem ;
1. Index.php edited, Forumhome not changed.
2. Forumhome edited, Index.php not changed.
3. Both changed.
Is it the standard vB Forumhome template, or a custom one ?
Do you have a test user ? Also, can you PM me your edited index.php.
Paul M
05-06-2005, 06:53 PM
BTW, not related, but just reading your forum I noticed you had changed the refresh time from 3 secs to 0.1 secs - this is a very bad idea - 2 seconds is about the minimum you should consider. Basically you are telling every user to poll the server every 0.1 seconds - using large amounts of bandwidth and eventully if quite a few join, collapsing the whole thing. (Imagine trying to refresh a normal page 10 times a second !!).
Acers
05-07-2005, 12:35 AM
thanks for telling that.
Actually i did that as a test to see if it fixes lag. Right now all were complaining of some 7 to 30 secs lag. I tried to test the chat with high refresh to see if it did anything. It hasn't. Ar best its now variable with some users getting it way too high and some low.
Anyway i will make it back to 2secs.
the problem is caused only on
1. Index.php edited, Forumhome not changed.
(or even if i change forumhome, and don't edit the index.php its allright. Its only on index.php file edit that it occurs.)
btw i just sent you some details via pm(index file and test user details.)
Sleazy
05-15-2005, 04:00 PM
I am trying to use this code in collaboration with AdColumns so that it has a Whos in chat display on a side column. I put this code in a template being called by AdColumns but it doesn't appear to work this way. The template is being called on ForumHome, is there anything you can think of that would fix this problem so the code can function as part of a template that is being called?
Paul M
05-15-2005, 05:25 PM
I don't know much about adcolumns - and am not really sure what you are saying doesn't work. Can you be more specific, or link to your site.
Paul M
05-15-2005, 09:25 PM
Sleazy - thanks for the PM - I have replied with what should be the answer for you.
T3MEDIA
05-15-2005, 10:55 PM
hey paul should I bother with flash chat?
dsboyce8624
05-15-2005, 11:59 PM
hey paul should I bother with flash chat?
AFAICT FlashChat is the best out there right now.
I have it, and this hack installed. Both running smoothly.
Paul M
05-16-2005, 12:14 AM
hey paul should I bother with flash chat?Well that depends - do you want a chat system ?
If so then yes, FC does the job (as do others I might add, but I, and many others chose this one).
Romeos Tune
05-16-2005, 01:19 AM
Hey Paul,
I'm running VB3.03 and the latest FlashChat.... For some reason I'm getting this error. It's adding an extra vb3_ it seems when doing the queries.... I'm still too new to figure this out I guess..... Any help would be appreciated.....
Database error in vBulletin 3.0.3:
Invalid SQL: SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM vb3_vb3__fc_connections as connections
LEFT JOIN vb3_vb3__fc_rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN vb3_user as user ON(connections.userid = user.userid)
LEFT JOIN vb3_usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN vb3_usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start
mysql error: Table 'vb.vb3_vb3__fc_connections' doesn't exist
mysql error number: 1146
esology
05-16-2005, 01:41 AM
Romeos Tune,
I am getting the exact same error. Still trying to figure out what it is.
Paul M
05-16-2005, 11:38 AM
Hey Paul,
I'm running VB3.03 and the latest FlashChat.... For some reason I'm getting this error. It's adding an extra vb3_ it seems when doing the queries.... I'm still too new to figure this out I guess..... Any help would be appreciated.....
Database error in vBulletin 3.0.3:
Invalid SQL: SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM vb3_vb3__fc_connections as connections
LEFT JOIN vb3_vb3__fc_rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN vb3_user as user ON(connections.userid = user.userid)
LEFT JOIN vb3_usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN vb3_usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start
mysql error: Table 'vb.vb3_vb3__fc_connections' doesn't exist
mysql error number: 1146Which versions of flashchat, and this hack are you using ?
The 'vb3_' is your vB table prefix, because it assumes the flashchat tables were also created with this prefix. On top of this there is also a flashchat prefix which was added in 4.0.x which has complicated matters. Does your chat actually work ? What are you flashchat tables actually called ? What prefix (pref) is defined in your flashchat config.srv.php ?
esology
05-16-2005, 12:19 PM
Which versions of flashchat, and this hack are you using ?FlashChat 4.0.6
Whos chatting Hack 2.16
The 'vb3_' is your vB table prefix, because it assumes the flashchat tables were also created with this prefix. On top of this there is also a flashchat prefix which was added in 4.0.x which has complicated matters. Does your chat actually work ? Yes, chat works fine
What are you flashchat tables actually called ? What prefix (pref) is defined in your flashchat config.srv.php ? vb3_fc
Paul M
05-16-2005, 01:24 PM
Okay, looks like flashchat 4.0.x now ignores the vB prefix (except at install ?) and just uses it's own internal one.
Try replacing the code in index.php with this 2.17 version and let me know how it goes.
// ## Paul M - Flashchat - Who is in the chat v2.17 ## //
$fcfolder = 'chat';
// ## Make sure the folder name defined above is the correct name of your flashchat installation folder ## //
$GLOBALS['fc_config_stop'] = true;
require_once("./" . $fcfolder . "/inc/common.php");
$fcprefix = $GLOBALS['fc_config']['db']['pref'];
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . $fcprefix . "connections as connections
LEFT JOIN " . $fcprefix . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
unset($chatters);
$totalchatters = 0;
while ($chat = $DB_site->fetch_array($chatlist))
{
$totalchatters += 1;
$roomname = "In private room";
$chat['opentag'] = $chat['opentaga'] ;
$chat['closetag'] = $chat['closetaga'] ;
if ($chat['displaygroupid'])
{
$chat['opentag'] = $chat['opentagb'] ;
$chat['closetag'] = $chat['closetagb'] ;
}
if ($chat['ispublic']) { $roomname = "In ".$chat['name']; }
$chatters .= "<a href='member.php?u=$chat[userid]' title=\"$roomname\" >";
$chatters .= $chat['opentag'].$chat['username'].$chat['closetag']."</a>, ";
}
if ($chatters)
{
$chatters = substr($chatters, 0, strlen($chatters)-2);
}
else
{
$chatters = "No one is currently using the chat";
}
// ############# End of Who is in the chat ###############
If this cures it then I will update the first post.
esology
05-16-2005, 01:42 PM
Thanks Paul! Works like a charm.
Paul M
05-16-2005, 02:29 PM
Thanks Paul! Works like a charm.Good. I have updated the install file. I hope they don't change this behaviour again ......
Romeos Tune
05-16-2005, 10:39 PM
Thanks Paul! That fixed my problem too.... Awesome! :)
dfaonxa
05-18-2005, 04:58 AM
Just wanted to say thanks for the mod, works perfectly and so easy to install! Thanks! :up:
plateau
05-18-2005, 10:53 AM
good job!
install clicked!!!
Cyricx
05-18-2005, 06:57 PM
Running vb 3.0.7 and flash chat 4.0.6
Works great!! :)
No errors at all, only bug I noticed is that it counts bots as being in the room(bad), but doesn't list them in the Who's In Chat(good).
We have 1 bot in our chat so unfortunately it never thinks noone is in chat thought it will have a blank area where the names list heh.
Cyricx
05-18-2005, 07:51 PM
the inthechat.php is missing the code to grab the template..
Find
?>
And Add ABOVE it:
eval('$home[$onlineid][\'content\'] = "' . fetch_template('adv_portal_ts') . '";');
Has the same problem as the forumhome section in counting bots though.
Paul M
05-18-2005, 10:53 PM
the inthechat.php is missing the code to grab the template..
Ooops, well spotted - a slight copy/paste error when I updated it - I overwrote the template call ....
Updated and re-uploaded. :)
Cyricx
05-18-2005, 11:52 PM
Okay Paul, I debugged the rest for ya :)
Here's the other things you'll need to add to correct the module to work.
For the forumhome hack so that it doesn't pick up the bots, also find this code in the inthechat.php file to fix it for the module.
Replace this:
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . $fcprefix . "connections as connections
LEFT JOIN " . $fcprefix . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
with this:
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . $fcprefix . "connections as connections
LEFT JOIN " . $fcprefix . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL AND connections.ip != '0.0.0.0' ORDER BY start" );
That'll fix the forumhome.
The last fix for the module is open inthechat.php and find:
<?
AFTER IT, Add:
foreach ($modules AS $omods)
{
if ($omods['identifier'] == 'flashchat' AND in_array($omods['modid'], explode(',', $pages['modules'])))
{
$showonline = true;
$onlineid = $omods['modid'];
}
}
unset($omods);
And go into your admincp, edit modules and set the module indentifier as
flashchat
That'll fix all the quirks :)
Awesome work Paul, thank you so much, I never could have coded this myself :), I can tweak code like crazy, but I can't write a damn thing from scratch LOL!
Paul M
05-19-2005, 12:04 AM
Okay Paul, I debugged the rest for ya :)
Here's the other things you'll need to add to correct the module to work.
For the forumhome hack so that it doesn't pick up the bots, also find this code in the inthechat.php file to fix it for the module.
And go into your admincp, edit modules and set the module indentifier as
flashchat
That'll fix all the quirks :)
Awesome work Paul, thank you so much, I never could have coded this myself :), I can tweak code like crazy, but I can't write a damn thing from scratch LOL!Chris - I'll update the CPMS module and it's instructions later (see your PM) - we don't have the portal installed so I can't test it myself (hence why it's not supported).
As regards the bots - these are a new feature of FlashChat 4.0.x - you are the first person to ask about not displaying them. I personally don't use them anyway. The code you have added will technically work if you haven't changed the bot ip address in the f/c config file - but if I add this to the hack then I will make sure it reads the configured ip, and also make it optional as some people my want the bots listed.
Thanks for your post. :)
Cyricx
05-19-2005, 01:05 AM
Ah bugger, I did make a typo in my first post.
Here is the attached editted inthechat.php file with the changes I made.
Paul M
05-19-2005, 01:36 AM
Cheers - I have written v2.20 which includes the option to not show bots - but I can't test it until tomorrow. If it works then I will upload it and a new corrected module as well. Thanks for you help with the CPMS bit. :)
Cyricx
05-19-2005, 01:53 AM
Happy to help :)
weaver
06-02-2005, 02:07 PM
I can't get my forum page to open. :( I'm getting this error:
Warning: main(./chat/inc/common.php): failed to open stream: No such file or directory in /index.php on line 477
Fatal error: main(): Failed opening required './chat/inc/common.php' (include_path='.:/usr/local/php/lib/php') in /index.php on line 477
Here's what I have for my line 477:
require_once("./" . $fcfolder . "/inc/common.php");
diettalk
06-02-2005, 02:13 PM
did you change to show your correct chat directory?
$fcfolder = 'chat'; // The folder name where your flashchat installation is located //
weaver
06-02-2005, 02:23 PM
did you change to show your correct chat directory?
$fcfolder = 'chat'; // The folder name where your flashchat installation is located //
My chat folder is named chat so I don't need to change anything right? Is it a chmod issue?
Paul M
06-02-2005, 06:18 PM
My chat folder is named chat so I don't need to change anything right? Is it a chmod issue?No, more likely a non standard path problem, what is the url of your site ?
Paul M
06-02-2005, 08:52 PM
From the information you PM'd me, it looks like your chat is a folder level up from your forum (I would have thought you must have had to alter some paths in flashchat when you installed it) ?
Try ;
$fcfolder = '../chat'; // The folder name where your flashchat installation is located //
I'm off to bed in a couple of hours, and then away until next week. I'll check back in a bit to see if this fixed it, otherwise I'll check next week.
weaver
06-02-2005, 08:59 PM
No I didn't have to alter anything. I just installed the newest version and from the way the install directions read I thought that's where it was supposed to go. Everything worked correctly with Flashchat itself so I didn't think anything was out of the ordinary. I'll try your fix and let you know if it works. Thanks. :)
weaver
06-02-2005, 09:03 PM
That fixed it Paul. Thanks a lot. :) :)
EricaJoy
06-04-2005, 01:44 PM
*clicks install
Hi Paul,
is there anyway to Block Usergroups from the Chat?
Paul M
06-10-2005, 03:40 PM
Hi Paul,
is there anyway to Block Usergroups from the Chat?I'm not sure what this has to do with who's chatting - but I don't quite follow anyway - can you be more specific about your problem please.
I'm not sure what this has to do with who's chatting - but I don't quite follow anyway - can you be more specific about your problem please.
Hi Paul,
if i moved a user in a Group called moderate, they don?t use the chat and they don?t displayed too.
2. i asekd you, about to display most chatters an the day, a few weeks ago :)
Uyou insert the code in your new hack, wich contains who?s online,who?s chatting.
can i used the Part of the Code as standalone wich this one?
Paul M
06-10-2005, 07:12 PM
Hi Paul,
if i moved a user in a Group called moderate, they don?t use the chat and they don?t displayed too.
2. i asekd you, about to display most chatters an the day, a few weeks ago :)
Uyou insert the code in your new hack, wich contains who?s online,who?s chatting.
can i used the Part of the Code as standalone wich this one?TBH, I'm not entirely following you.
1. Are you saying you want to ban a group from using the chat ? If so then you need to install my Flashchat upgrades (https://vborg.vbsupport.ru/showthread.php?s=&threadid=74613) hack.
2. Most chatters is possible by installing all, or part, of my Most Ever Users/Members/Guests/Chatters (https://vborg.vbsupport.ru/showthread.php?s=&threadid=81167) hack.
HTH.
dsboyce8624
06-24-2005, 12:44 AM
And go into your admincp, edit modules and set the module indentifier as
flashchat
That'll fix all the quirks :)
This should be added to the instructions for the vBa, it really acts weird without it.
Paul M
06-24-2005, 01:51 AM
This should be added to the instructions for the vBa, it really acts weird without it.um, setting the module identifier is in the instructions ....
dsboyce8624
06-24-2005, 02:29 AM
um, setting the module identifier is in the instructions ....
HRm I must be losing my mind.
Oh well, reading the whole thread gave up the info I needed so either way I got it.
digidivakathy
07-07-2005, 10:17 PM
Hey, Paul...Last night I saw someone in the chat who wasn't there. When I looked at the db table today, they weren't even in the flashchat_users table. I apparently accidentally installed this in stateless CMS mode because the generic password worked for the admin panel (I've since changed the password), but my admin userid and password from the forums didn't. Anyway, any ideas what's going on?
Thanks!
Kathy
Paul M
07-07-2005, 11:33 PM
Kathy, you are not showing as having this installed, please click the link.
FYI - it won't work correctly unless you have it integrated - in stateless mode FC just assigns sequential userids to each new chatter, starting from 1 when you first install it.
Deepdog009
07-08-2005, 12:04 AM
Reading Helps, I fix my problem after reading all those dog gone posts. Im a getting better at it. My first days tho were hell. do U fill me? :tired:
./Flash <....
digidivakathy
07-08-2005, 12:06 AM
Sorry, Paul...I just clicked on install. I reinstalled it and am waiting to see if all is well. It's working for me and showing me in chat, so hopefully it's a go.
Thanks!
Paul M
07-08-2005, 11:09 PM
FYI, the older hack version 2.00 has been withdrawn, if you are still using an old version of Flashchat (3.9.x) then you can use version 2.20. If you have an older version than 3.9.x then I suggest you upgrade. :)
digidivakathy
07-12-2005, 03:37 AM
Ummm...a question, Paul? When I installed this, I completely skipped step 3 and it was still working wonderfully. After reading about buggy smilies in FlashChat, I upgraded to 4.0.12 and when I simply deleted old flashchat files and replaced them with new, I got a My SQL connect error...sorry, I can't tell you precisely what it was, something about couldn't connect with user name and password file inc/db.php. Anyway, since this message is coming from the forums home page, I didn't know if it was related to this hack or if it's a flashchat issue, but I figured I'd just ask both places. I undid the upgrade and am back to 4.0.9 and the message is gone, but I just don't know where to look for the problem.
Thanks!
Paul M
07-12-2005, 03:08 PM
Theres not really much I can tell you unless i see the error.
Step 3 makes sure you can connect to the correct tables in your database - did you make sure that the "pref" setting is correct in both versions - by default (in the downloaded FC 4.0.12 files) it is probably wrong. What is it set to in your 4.0.9 config.srv.php ?
digidivakathy
07-12-2005, 04:04 PM
Thanks, Paul. It's set to _fc_ in both files. Maybe late tonight, I'll put it back in long enough to copy the error message so you can see exactly what it says.
paul41598
07-13-2005, 11:03 AM
does anyone know why that if your in flashchat, your board runs sloooow. Its like you cant be in flashchat and on your forums at the same time, otherwise your internet seems like a 56k or something. Then once you log out of flashchat, your forums fly when you maneuver around them? Weird...
Paul M
07-13-2005, 04:43 PM
Why have you posted this exact question in two of my threads - it has nothing to do with my hacks.
arob42
07-15-2005, 04:58 PM
I've integrated flashchat with vbulletin 3.0.3 and I'm adding this hack, but after step 1 in the instructions where index.php is modified, I upload and refresh my forum page and see the following at the top of the page.
Warning: mysql_connect(): Access denied for user: 'arob42@localhost' (Using password: NO) in /chat/inc/classes/db.php on line 15
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /chat/inc/classes/db.php on line 16
Warning: mysql_connect(): Access denied for user: 'arob42@localhost' (Using password: NO) in /chat/inc/classes/db.php on line 15
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /chat/inc/classes/db.php on line 16
Warning: mysql_connect(): Access denied for user: 'arob42@localhost' (Using password: NO) in /chat/inc/classes/db.php on line 15
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /chat/inc/classes/db.php on line 16
Is it trying to access my vbulletin database using arob42 as my userid? This is only part of my userid, but it has been truncated. Anyone know what might cause this? Shouldn't the userid be fetched from config.srv.php?
Also, does this even work with 3.0.3?
Thanks,
--Robert
Paul M
07-15-2005, 06:42 PM
Shouldn't the userid be fetched from config.srv.php? No, if it's integrated correctly, the userid, password and database are pulled from your vB config.php.
Those errors are from the flashchat code, not vB. What version of Flashchat are you using, and which CMS file ?
arob42
07-16-2005, 02:55 AM
I'm using flashchat v4.0.12 and vbulletinCMS.php. I've modified the vbulletinCMS.php file with my license number, and I removed the 2 blank lines at the end of the file. I verified that when I'm logged into my vbulletin forum I enter straight into the chat room, and when I'm logged out I am prompted for my username/password when accessing chat. It will take my vbulletin username/pass at this point and I'm back in chat. My chat directory is located at my forum root, as per instructions, not the website root. I removed the flashchat databases and reinstalled everything but still get the same result. It's probably something stupid I'm doing but I don't see it yet.
Paul M
07-16-2005, 04:21 AM
Sorry, but I would need to access your server files to see what is going on - it makes no sense at all.
wattieuk
07-16-2005, 12:56 PM
<font color="SandyBrown">Deleted: solved it!</font>
Paul M
07-16-2005, 08:04 PM
I'm using flashchat v4.0.12 and vbulletinCMS.php. I don't know why 4.0.12 has caused this to happen for some people - but there is no requirement for that bit of code to actually be called, it's just a side effect of calling the flashchat common.php - I have altered the code to avoid this now anyway, new version v2.25 uploaded. :)
digidivakathy
07-25-2005, 02:11 AM
Okay, Paul, I finally switched it long enough to get the error...here it is:
Warning: mysql_connect(): Access denied for user: 'kathyssi@localhost' (Using password: NO) in /flashchat/inc/classes/db.php on line 15
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /flashchat/inc/classes/db.php on line 16
Warning: mysql_connect(): Access denied for user: 'kathyssi@localhost' (Using password: NO) in /flashchat/inc/classes/db.php on line 15
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /flashchat/inc/classes/db.php on line 16
Warning: mysql_connect(): Access denied for user: 'kathyssi@localhost' (Using password: NO) in /flashchat/inc/classes/db.php on line 15
Warning: mysql_query(): supplied argument is not a valid MySQL-Link resource in /flashchat/inc/classes/db.php on line 16
I have checked, double checked and triple checked and the login info for the database is the same in the old db.php file as it is in the new one. Any idea what's going on?
Thanks!
Paul M
07-25-2005, 12:11 PM
See the post above yours, replace your code with v2.25 and hopefully the problem should go away. :)
unknowngiver
07-29-2005, 11:49 AM
Hey i need help
i want to add whose chatting in the header
and i added this
<center><a href="http://www.apkafuture.com/chat/flashchat.php"><img src="http://www.apkafuture.com/LIVE.gif"</a>There are $totalchatters members in the chatroom <a href="http://www.apkafuture.com/chat/flashchat.php">Join Now</a></center>
in the navbar template
it works in the INDEX PAGE but it doesnt work in the other pages
wt should i do?
Paul M
07-29-2005, 07:17 PM
The code is located in index.php, so it will only generate the list on the forumhome. You would need to install the hack code elsewhere to have it on all pages. This is discussed earlier in the thread - starting about here (https://vborg.vbsupport.ru/showthread.php?p=641833).
derekivey
08-05-2005, 12:46 AM
For some reason it doesn't show the name of the bot thats in the room, it just shows a blank space. Any ideas on what is wrong?
Paul M
08-05-2005, 01:09 AM
Hmm, yes ......
It's never going to show their name - as its not stored anywhere except in a text file .... what a daft system.
Sorry, but I suggest you set $showbots = false; in the hack code as it's never going to work. I'm going to remove that bit for now as it cannot query a database to get the information.
I'll look at it sometime after my holiday to see how easy it is to get the data from the text file it uses, but it may just end up that bots will not be displayed by name, just called "bot", or possibly something like "Users currently in the Chat: 4 (Members: 3, Bots: 1)" with just the list of members.
derekivey
08-05-2005, 01:10 AM
Ok No Problem, I'll just do that.
Paul M ... thank you for this ... i've clicked install.
I have a question / request ... i hope it's not already been asked, as i've not read every post in this thread ... but ...
I'd like to know if you can help me put the online chatters in the header? I'm currently using Chen / Erwin's Online Users Mod (https://vborg.vbsupport.ru/showthread.php?p=456653#post456653), which does this for the online users. I'd like for my chatters to be listed up there too. I'd like it setup exactly as you have it below, only displayed above as well.
Is this possible ... can you help me?
Thanks a Bunch.
LTW
Paul M
08-05-2005, 01:36 PM
Drop me a PM and I'll look when I return from holiday - I don't have time before.
Prisoner
08-11-2005, 02:40 AM
I get the following error when I tried to install this.
Warning: main(./chat/inc/config.php): failed to open stream: No such file or directory in /index.php on line 299
Fatal error: main(): Failed opening required './chat/inc/config.php' (include_path='.:/usr/lib/php:/usr/local/lib/php') in /home/rwalker/public_html/forum/index.php on line 299
Anyone have any ideas? The forum and chat directories are at the same level...ie. /public_html/chat and public_html/forum.
Thanks!
Prisoner
08-11-2005, 10:19 AM
I got it to work by changing"
require_once("./" . $fcfolder . "/inc/config.php");
require_once("./" . $fcfolder . "/inc/config.srv.php");
to
require_once("/home/rwalker/public_html/" . $fcfolder . "/inc/config.php");
require_once("/home/rwalker/public_html/" . $fcfolder . "/inc/config.srv.php");
Was this a sound fix, or is there a better way?
sinoeu
08-15-2005, 09:16 PM
Well it took me a few minutes to figure out your mistake, but the small snippet of code finally gave it away.
You have put the hack code in the wrong file. It goes in vB's index.php - you appear to have installed it in flashchat's index.php.
There's no mistake like that in my case. But I still have no name display under the total chatters number display. However, when there's nobody in the chatroom, there is a display of "No one is currently using the chat" under the "Members currently in the Chat: 0" :disappointed:
who can tell me why? I am using FlashChat 3931 under vbb 3.07
Paul M
08-20-2005, 06:58 PM
Sorry, but 3931 is a very old version of Flashchat, I have no idea if this is still compatible with it.
Hi
Is this hack compatible with 3.5 RC2 as I seem to be having problems?
Joy :)
Paul M
08-30-2005, 08:55 PM
Not this version - there is a 3.5.0 plugin here;
https://vborg.vbsupport.ru/showthread.php?t=91338
Thanks very much, Paul :)
geoff4787
09-29-2005, 07:34 PM
I get an error on my index.php when I paste that code above the // ### LOGGED IN USERS #########################################
The error says this:
Fatal error: Call to a member function on a non-object in /home/global/public_html/index.php on line 317
Any clue as to what is wrong?
geoff4787
09-29-2005, 08:14 PM
Nevermind, I fixed that but I got a new error I need to post on the 3.50 thread for this.
Paul M
09-29-2005, 09:13 PM
Any clue as to what is wrong?Judging by you next post I would say you are installing the wrong version, this is for 3.0.x :)
Paul M
10-21-2005, 04:16 PM
Are you sure you are in the right topic, there is no such facility in this (3.0 version).
Paul M
10-21-2005, 04:21 PM
isn't this the Flashchat: Who is chatting area?Only for vb 3.0.9 (or older).
netrosearch
10-23-2005, 01:06 AM
Well, I did the the install but this is what I get:
Fatal error: Call to a member function on a non-object in /home/savetheo/public_html/orcaclub/communitypod/index.php on line 316
Any ideas? Copied everything as it was listed in the instructions and checks all the variables.
Paul M
10-23-2005, 02:55 AM
Check Step 3, are you sure the prefix in config.srv.php is correct ?
Edit: Actually, you have also posted in the vb3.5 integration thread, you do realise that this hack is for 3.0.x, not 3.5.0 ?
zendiver
10-25-2005, 08:53 PM
Paul, got a question for you....it may have already been asked but I didn't see it. Why is that users still show up in the "Users Currently Inside Chat:" LONG after they have left? Sometimes even the following day. Is there somewhere that this can be refreshed more often?
thanks
-ZD
derekivey
10-25-2005, 09:19 PM
Thats the way that FlashChat keeps track of users logged in. It's really weird. This hack has nothing to do with that problem.
Paul M
10-25-2005, 09:25 PM
Paul, got a question for you....it may have already been asked but I didn't see it. Why is that users still show up in the "Users Currently Inside Chat:" LONG after they have left? Sometimes even the following day. Is there somewhere that this can be refreshed more often?
thanks
-ZDThis has multiple mentions in the thread, but here it is again ....
Basically it's down to Flashchat not removing them from the connections table. This happens because the user does not log out properly, but instead just closes their browser. When a user does this, Flashchat attempts to run a little pop-up to log them out, but browsers like firefox block this - so they don't get logged out.
These dead sessions only get removed when they time out, and since timeout processing only happens when someone is connected, if the last person in the chat does this, their 'connection' can end up being displayed for ages.
The answer is to drill the users in to logging out properly, or getting them to allow pop-ups from your site.
Coldhands
10-27-2005, 03:33 AM
This might be user error on my part, but when I cut and paste the code into the main index.php file just above where it says I should, and upload the new file, I get a blank screen when I point my browser at my forum. I've changed the ForumHOME template code too. In the config file it has
'pref' => 'flashchat_',
Am I missing something?
I just installed Flash Chat 4.4.1 and I'm using vB 3.5.0.
I feel like an idiot right now. Please help. :/
Paul M
10-27-2005, 05:11 AM
This is not for vb 3.5, it is the 3.0.9 version.
Look in the 3.5 plugins area for the 3.5 version, or click on the my hacks link in my sig.
Im having trouble.
i do not understand what i have to edit with the index.php. i know where it goes but what exactly do i add and where.
sorry for sounding so stupid.
its a fresh install of the latest version on VB 3.0.9
// ## Paul M - Flashchat - Who is in the chat v2.30 ## //
$fcfolder = 'chat'; // The folder name where your flashchat installation is located //
$GLOBALS['fc_config_stop'] = true;
require_once("./" . $fcfolder . "/inc/config.php");
require_once("./" . $fcfolder . "/inc/config.srv.php");
$fcprefix = $GLOBALS['fc_config']['db']['pref'];
$chatlist = $DB_site->query("SELECT connections.userid, connections.roomid, rooms.name, rooms.ispublic, connections.start,
user.usergroupid, user.displaygroupid, user.options, user.username, groupa.opentag as opentaga, groupa.closetag as closetaga,
groupb.opentag as opentagb, groupb.closetag as closetagb
FROM " . $fcprefix . "connections as connections
LEFT JOIN " . $fcprefix . "rooms as rooms ON(connections.roomid = rooms.id)
LEFT JOIN " . TABLE_PREFIX . "user as user ON(connections.userid = user.userid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupa ON(user.usergroupid = groupa.usergroupid)
LEFT JOIN " . TABLE_PREFIX . "usergroup as groupb ON(user.displaygroupid = groupb.usergroupid)
WHERE connections.userid IS NOT NULL ORDER BY start" );
unset($chatters);
$totalchatters = 0;
while ($chat = $DB_site->fetch_array($chatlist))
{
$totalchatters += 1;
$roomname = "In private room";
$chat['opentag'] = $chat['opentaga'] ;
$chat['closetag'] = $chat['closetaga'] ;
if ($chat['displaygroupid'])
{
$chat['opentag'] = $chat['opentagb'] ;
$chat['closetag'] = $chat['closetagb'] ;
}
if ($chat['ispublic']) { $roomname = "In ".$chat['name']; }
$chatters .= "<a href='member.php?u=$chat[userid]' title=\"$roomname\" >";
$chatters .= $chat['opentag'].$chat['username'].$chat['closetag']."</a>, ";
}
if ($chatters)
{
$chatters = substr($chatters, 0, strlen($chatters)-2);
}
else
{
$chatters = "No one is currently using the chat";
}
you say add * Make sure you have set the parameter in the Step 2 code * well step 1 really lol.
My prefix is _fc_.
any help on what i add and where.
any help is much appreciated.
The chatroom works fine just this.
site if needed http://http://gamezmania.com
Paul M
11-18-2005, 03:36 PM
Im having trouble.
i do not understand what i have to edit with the index.php. i know where it goes but what exactly do i add and where.
you say add * Make sure you have set the parameter in the Step 2 code * well step 1 really lol.
My prefix is _fc_.
any help on what i add and where.
1. Add the code to index.php in the correct place, the parameter is already correct.
2. Check the prefix in flashchats config.srv.php is correct.
3. Do the template edit.
4. Done.
It was more where on the file for index.php i add the _fc_ to get it to work ive tried a few to no avail
Paul M
11-18-2005, 11:31 PM
It was more where on the file for index.php i add the _fc_ to get it to work ive tried a few to no availYou don't add it to index.php.
Like I said ;
2. Check the prefix in flashchats config.srv.php is correct.That is where the prefix is defined (as 'pref' iirc)
thanks for that was just confused.
vBulletin® v3.8.12 by vBS, Copyright ©2000-2024, vBulletin Solutions Inc.