vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Flashchat: Who is chatting (https://vborg.vbsupport.ru/showthread.php?t=73042)

Paul M 05-18-2005 10:53 PM

Quote:

Originally Posted by Cyricx
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:
Code:

$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:
Code:

$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:
Code:

<?
AFTER IT, Add:
Code:

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

Quote:

Originally Posted by Cyricx
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:

Quote:

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

Quote:

Originally Posted by diettalk
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

Quote:

Originally Posted by snobbymom
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 ?


All times are GMT. The time now is 01:12 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
  • Page Generation 0.01232 seconds
  • Memory Usage 1,750KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (4)bbcode_code_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

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

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