![]() |
[Add on] Who's Chatting on Forum Home Page for Sigmachat
Add-on by ChurchMedia
Who's Chatting on Forum Home Page for Sigmachat You must have the SigmaChat Complete Integration & Authentication hack installed first and be signed up with SigmaChat, of course. This will add a "Who's Chatting" box on your forum home page. Just like "Who's Online", if you click on "Who's Chatting" it will take you to a page with just the chatters. If you are logged in, there is a link to the chat room. If you are not logged in, there is a link to register. ~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~- Note that the problem of having a space in your user name is corrected. However, if the user name has an _underscore_ in it there may be problems. To remove the feature that replaces underscores with spaces, remove this line (Line 57 in chat_home.php): PHP Code:
1 new template 2 template changes WARNING #1: This hack WILL speed up your Who's Chatting hits! If you seriously want Who's Chatting on your front page, keep in mind that you may have to buy extra hits! Otherwise, don't install this hack! :) I've found that it increased my chat room traffic dramatically, so I think it's worth buying the hits. WARNING #2: When you do run out of Who's Chatting hits, your forum home page will break (you will get a blank page)! If this happens, in forum/index.php FIND PHP Code:
PHP Code:
|
I've put your one-liner in php tags so unlicensed users can't see it - better safe than sorry ;) Thanks for sharing your work with the community once again :D!
|
This or at least a number display for chatters has been requested for a long time but won't this consume your "Who's chatting" hits from Sigmachat at a drastic rate? If it's only refreshed every so often (10 minutes or longer) I'll install this afternoon but if it's live and refreshes with every page view... ouch!
|
Quote:
|
Quote:
I don't see a way around the problem of it hittng everytime someone visits the home page... Personally, my chat room is so popular I'm willing to spend the extra money for the hits if I have to. |
They allow you 146 hits per day I think it is (carried forward) which works out to about 1 per every ten minutes 24/7. If there was a way to cache the who's online data for 10 minute intervals it would be just about perfect. I believe that once their new release goes final that the updated integration script will include some type of feature like that but being so close to things changing they haven't bothered. I made a similar error by placing the total number of chatters next the chat link in the nav bar and a few days later I was out of hits for the rest of the month. Whoops...lol
|
I didn't think there was a limit on paid accounts.
|
There is indeed... it's just that most paid accounts get more than they use and they are compounded over time.
https://vborg.vbsupport.ru/showpost....3&postcount=69 |
Right -- you do have to pay for the Who's Chatting hits. My forum burned through 5000 hits in a few days. When you run out of hits, the forum home page BREAKS with this hack (blank page). You have to disable the hack, buy more hits and re-enable it when your upgrade goes through.
I'm still deciding if it's worth it, but I think it is. Chat traffic when up dramatically when I installed this hack. When I have more time, I'll look into caching the info to slow down the hits. |
Best way, IMHO, is to cache the who's on line stuff as a cron job, once every 6 minutes :)
|
Good idea! I'd still need to do some new coding to make that happen. I'll be out for a few weeks, but I'll try to get back to it. Feel free to work on it if you like :)
|
If someone is able to pull that off... I'm definitely interested!
|
I actually have it running on my forum right now. I'll do some cleanup and upload the script + instructions.
|
What's the refresh rate for updates tamarian?
|
It would be up to you, as it's a cron job and can be set to any rate. I initially thought we could do once every 6 minutes, but SigmaChat gives less credit, so now I have it at once every 10 minutes.
Hey, I see you're in Ottawa, me too :) |
Quote:
Quote:
|
Quote:
Of course, you can have both working if you want to, but there's no need. Template #1 has something like this "Currently chatting: 3 members" Template #2 has something like this "user1, user2, user3" I put template #1 in the forum home stats box, and template #2 in the what's going on box. |
Ok so any news on the cache/cronjob update?
|
Quote:
|
Quote:
|
O.k., here goes:
Note: You need the chat_global.php from the sigma chat hack provided by sigmachat. 1. Create a new file called chat_cache.php or something else, and paste this into it: PHP Code:
3. Create two empty templates: sigmachat_chatting_cache_bit and sigmachat_chatting_cache 4. Edit index.php Find: PHP Code:
PHP Code:
PHP Code:
PHP Code:
6. Add a cron job to your server, ever 10 minutes. Example: */10 * * * * /usr/bin/php /path/to/forum/chat_cache.php > /dev/null 2>&1 7. If you have a problem, feel free to ask, but keep in mind that you need to back up your files and templates in case it doesn't work for you. |
This is my first time trying to add a cron job to my site, and I have no idea where to begin. Where do I put that bit of code in?
|
Alright nevermind, I just asked my hosting company and they rudely told me they don't support it. Jerks.
I've got it installed and the link goes to the embedded chat... I want it to pop up. I don't know how to change it :( EDIT: Woot, fixed it. Ain't it great when you go begging for help, and then figure out how to do it all by yourself? I feel like such a big boy now. |
/cloaked users show in who online.....anyone else notice this?
|
How come mine is showing -1 Users when there is indeed 0 folk in my room :nervous:
|
hi,
have someone a plugin for vb3.5. i want display the userĀ“s on my forumhome! |
All times are GMT. The time now is 08:18 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|