AjaxChat Integration (latest version 3.2.1)

Started by .HuNTeR., August 27, 2008, 12:59:06 AM

Previous topic - Next topic

mrtrc266

@ Youngiiie I don't believe there is a command for "Help" but on the bottom right of the ChatRoom there is a picture "?" that opens up the help window.

To load a certain amount of previous messages find and change "10" to whatever you prefer

/chat/lib/config.php
// Max number of messages to display on each request:
$config['requestMessagesLimit'] = 10;

fext

#2441
How would you get them to show? Is there a command to bring up the previous messages?

Is there a way to default number of messages displayed for a user? If I click the settings tab and made mine 50 how would I make that the default for everyone?

.HuNTeR.

3.2
June 13 2009:
New features:
+ Chat moderate permission added.
+ Shoutbox view/shout/moderate permission added.
+ Improvements in coding for less manual edits in 3rd party themes.


Bug fixes:
- users in chat become moderator when they have calender post right.
- some minor bug in smf 2 fixed.

Chit-Chat ChatterBox Boss

Quote from: Youngiiie on June 12, 2009, 05:19:11 AM
Hello again!

Does anyone know if there is a command list for the chat?

Things like /help to bring up a list of commands or is there and actual command list?

Also is there a command to load in previous messages? something like /history+10

I have made a /commands command and also a button in the users online area 'List Commands'. If you want to see it you can go to my site I will be in the chat. Register on the site to view the chat button go in the chat I will be there and you can use the command if that is what you are looking for I will ask you for your files and I will make the edits needed.

(If you do sign up put 'Caleb' as a referral  :P)
Chit-Chat ChatterBox

Our site is open to everyone. It is a resource for anyone and everyone to talk about anything and everything you could possibly think of. It's a great place to come and talk, ask questions, or just simply hang out. We offer many great features. All we ask is that you follow by the site rules. Hope to see you around!
www.chitchatchatterbox.com
Remember in the "Referral" box to put "Caleb" while registering.

Chit-Chat ChatterBox Boss

Quote from: Chit-Chat ChatterBox Boss on June 10, 2009, 06:20:38 PM
@mrtrc266 and @ SunKing

I don't know if you two remember maybe about a week ago I talked to both of you (different times) about the shoutbox message limit per minute. mrtrc266 & SunKing you both tried it and said it does not work (same with me). I just wanted to clarify we are all retarded about this LOL because in the script where it is coded into AJAXChat.php it is coded for it not to apply for admins and moderators ;D. So that means all 3 of us trying it on our main account thats why it is not working. I tried it on my sites test account and it worked. Now that has been stated ..... I have a few questions.


  • Where can I change the time for the limit. Right now it is 1 minute = how many messages you set allowed. I want it to be like 5 minutes = how many messages you set allowed.
  • Where can I change the message that pops up (right now its this) "Error: You exceeded the maximum number of messages per minute." to like "Error: You exceeded the maximum number of messages per every 5 minutes. Please submit only 1 message within a 5 minute period." (I want this changed only when I get #1 changed).
  • In the Online Users box I want to add a 'Command List' button so people can just click it and it runs off my '/commands' command. Do you know how I can add this?
I figured out #1
function floodControl() {

// Moderators and Admins need no flood control:

if($this->getUserRole() == AJAX_CHAT_MODERATOR || $this->getUserRole() == AJAX_CHAT_ADMIN) {

return true;

}

$time = time();

// Check the time of the last inserted message:

if($this->getInsertedMessagesRateTimeStamp()+60 < $time) {

$this->setInsertedMessagesRateTimeStamp($time);

$this->setInsertedMessagesRate(1);

} else {

// Increase the inserted messages rate:

$rate = $this->getInsertedMessagesRate()+1;

$this->setInsertedMessagesRate($rate);

// Check if message rate is too high:

if($rate > $this->getConfig('maxMessageRate')) {

$this->insertChatBotMessage(

$this->getPrivateMessageID(),

'/error MaxMessageRate'

);

// Return false so the message is not inserted:

return false;

}

}

return true;

}


I changed
if($this->getInsertedMessagesRateTimeStamp()+60 < $time) {
means 60 seconds so if I set it to 
if($this->getInsertedMessagesRateTimeStamp()+300 < $time) {
then it will be 
$config['maxMessageRate'] = 1;
per every 5 minutes (300 seconds)

I am guessing #2 is in the AJAXChat.php or in the en.php so I will find that

#3 I figured out and mentioned a few posts back.

If anyone needs any help on how to do this stuff just ask ...... I can edit it for you. If you want me to do the edits for you might be faster to contact me on my site.
Chit-Chat ChatterBox

Our site is open to everyone. It is a resource for anyone and everyone to talk about anything and everything you could possibly think of. It's a great place to come and talk, ask questions, or just simply hang out. We offer many great features. All we ask is that you follow by the site rules. Hope to see you around!
www.chitchatchatterbox.com
Remember in the "Referral" box to put "Caleb" while registering.

llyon

Quote from: mrtrc266 on June 12, 2009, 10:25:03 AM
Quote from: llyon on June 12, 2009, 03:24:49 AM
Well, that worked - I now have the shoutbox, but the chat is asking for username & password - but it will not accept the forum credentials.

Did you drop the tables from your database and remove the /chat folder before installing the AJAX Chat Intergration Mod?

Yeah mate - completely obliterated it.

Zeshin

Hey guys. Just wanted to say that I think this mod is really good and whoever made it did a great job on it. :D

But, I do have one question.. I just installed the 3.2 version on my SMF 2.0 RC1 forum and I want to get the shoutbox to appear right above the footer. I'm having some trouble figuring this out.. can anyone help me with this?

Thanks in advance. :)

[unplugged]

I can. I had it at the bottom of my test site at one time. Attach your index.template.php and your BoardIndex.template.php, as I cannot remember which one I edited to move it.  :P
« Next Edit: Tomorrow at 08:34:45 PM by SunKing »   <---- « someone stole my sig... :o »



Zeshin

#2448
Here they are. Thanks. :)

Edit: Actually, I couldn't find any HTML that I could move around in the file. As far as I could tell, the reason why it's in the place that it is currently is because of this code in Load.php:


$context['template_layers'] = array('html', 'body');
array_splice($context['template_layers'], 2, 0, 'shout');


But, that was just from me playing around with it after an hour or so. ;X

[unplugged]

I moved it within the index.template.php. This puts it at the bottom of the page. Enjoy.
« Next Edit: Tomorrow at 08:34:45 PM by SunKing »   <---- « someone stole my sig... :o »



Zeshin

Actually, now it shows up at the top and the bottom and the bottom doesn't work. :(

http://aedolyn.net/tech/forum/

^ That is my test forum, if you don't mind registering to take a look. :\

[unplugged]

I am registering now. ;)

Meanwhile, you can have a look at it in action here:  http://www.empireofthesun.net/testsite/index.php#bottom
« Next Edit: Tomorrow at 08:34:45 PM by SunKing »   <---- « someone stole my sig... :o »



.HuNTeR.

@Zeshin
replace your index.template.php and boardindex.termplate.php with original one
open Sources/Load.php
find:

array_splice($context['template_layers'], 1, 0, 'shout');


replace with

//array_splice($context['template_layers'], 1, 0, 'shout');


open your index.template.php or boardindex.termplate.php and place

template_shout_above();

anywhere you want

@mrtrc266 please add this to the FAQ

Krandall

SunKing,

I edited my index.template, got it to how it should look, but for some reason, chat doesn't show up..... here's my index? Can you see what I'm doing wrong?

-Randy

[unplugged]

I am off to bed now Krandall (I have a 6 hour canoe trip tomorrow  :P ) but I will take a look at it when I get back. Or maybe somebody else can help you with it before then. Either way, we will get it sorted for you.

EDIT: At quick glance, the code looks fine in the index.template.
« Next Edit: Tomorrow at 08:34:45 PM by SunKing »   <---- « someone stole my sig... :o »



Joe N

Microsoft: "We Need to Imagine Life Without Walls."
I Say: "If There are No Walls Who needs Windows."



My Mods (6) All My Mods Updated To SMF 2.0 RC2 and SMF 1.1.10!


drhamza

#2456
QuoteFatal error:  Call to undefined function chatOnlineUsers() in /home2/jumssnet/public_html/forum/Sources/Load.php(2012) : eval()'d code on line 426


that's what i got after uninstalling the ajax chat integration mod.....

i opened the load.php, line 426 is empty...... i searched for chat but nothing was there

help me please


www.jumss.net/forum
user: tester    pass: tester

drhamza

by the way, i uninstalled it to install 3.2.... next time, do i have to uninstall anything or upgrading would be enough?

thank you

.HuNTeR.

only uninstall the previous version and install new one

Paracelsus

Quote from: .HuNTeR. on June 13, 2009, 07:50:58 AM
only uninstall the previous version and install new one

If I want to install it manually? Is there a file change log?

Advertisement: