AjaxChat Integration (latest version 3.2.1)

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

Previous topic - Next topic

allumius

Quote from: Youngiiie on June 11, 2009, 01:04:07 PM
Quote from: allumius on June 11, 2009, 12:43:36 PM
Well, i'm change my theme. Now i use BlackRainV2118
The chat work fine, but.... is posibble chat show only the last 10 lines? And the other whit scroll

I tink you need to find the guide by mrtrc266 - http://www.simplemachines.org/community/index.php?topic=257973.msg1981766#msg1981766

:)

Loads of info in there
i have read this thread, but i dont see the solution, and muy ShoutBox is very big and have now 35 lines!!!!!

fext

I presume you are talking about the AjaxChat popup...Try this... Although I am no expert...

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


And change the numerical value to what you need - you may also need to look at other files - mrtrc266 can help with this more I think :)

If you are talking about the shoutbox then I think you need to either look at other settings files (mrtrc266 can help more) or mess about with the CSS that controls the display of the shoutbox?

Can anyone else help?

allumius


fext

Then I am sure mrtrc266 will help :)

But you could try what I mentioned above.. MAKE A BACKUP OF ANY FILE YOU MODIFY

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


and edit the number - see if that works :)

Chit-Chat ChatterBox Boss

Quote from: allumius on June 11, 2009, 12:43:36 PM
Well, i'm change my theme. Now i use BlackRainV2118
The chat work fine, but.... is posibble chat show only the last 10 lines? And the other whit scroll

It is the same exact edit I gave a tut on a few pages back for the shoutbox. Just with this you edit the chat.css .... I can get the exact edit later (about to bring my fiance to work) or you can go here:
http://www.simplemachines.org/community/index.php?topic=257973.msg2102583#msg2102583
and see what you edit in the shoutbox.css and do the edits in the same location but in the chat file (not shoutbox.css as that is for the shoutbox).
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.

fext

I knew it was CSS :) just thought it might also have a setting for most lines - cheers dude!

Lighting_site


fext

Yeo it works for me wicked

Chit-Chat ChatterBox Boss

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, 12:09:43 AM
@ mrtrc266
To get around that make your chatbot smarter mod for the command situation I just added a new command called '/commands' into AJAXChat.php and if admins & mods do the command it lists all their commands and then for users their commands are listed. Was trying to do this for the smarter chatbot mod but it didn't like the user roles being used so it was easier to make a fresh command in AJAXChat that already used user roles. Now I will just use the smarter chatbot just for things without user role ...... except for the future I would still like to figure out how to get user roles to work in the smarter chatbot setup.

Only thing I am fighting that I want to know if you know how to add is in the Online Users box I want to add a 'commands' button so people can just click it and it runs off my '/commands' command. Do you know how I can add this?

I figured it out after studying the en.js and chat.js ...... I was doing everything correct in the chat.js just forgot to put the string into en.js for the button to show  :-[ But with trial and error I figured it out! :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.

Krandall

Quote from: SunKing on May 31, 2009, 11:43:26 PM
@Krandall

You could try setting up the shoutbox as a function as I posted a few posts up, then wrap the shoutbox(); inside the if(isset($board) && $board==21 || $board==22 || $board==23 || $board==24 || $board==32 || $board==33 || $board==55) {....}

Would look something like:

if(isset($board) && $board==21 || $board==22 || $board==23 || $board==24 || $board==32 || $board==33 || $board==55) {
shoubox();
}

Here's what I have (Below) when I do it this way, the shout box doesn't show on any pages.  ? Thoughts?


//shoutBox

if(isset($board) && $board==1.0 || $board==33.0) {
shoubox();

if (!empty($modSettings['enableShoutBox'])){
if (allowedTo('shout_access')){
// We'll have to use the cookie to remember the shoutBox header...
if ($context['user']['is_guest'])
$options['sb_collapsed'] = !empty($_COOKIE['sb_collapsed']);

echo '
<script language="JavaScript" type="text/javascript">
var sb_current_header = ', empty($options['sb_collapsed']) ? 'false' : 'true', ';

function ajax_shoutBox_collapse(mode)
{';

if ($context['user']['is_guest'])
echo '
document.cookie = "sb_collapsed=" + (mode ? 1 : 0);';
else
echo '
smf_setThemeOption("sb_collapsed", mode ? 1 : 0, null, "', $context['session_id'], '");';

echo '
document.getElementById("ajax_shoutbox_collapse").src = smf_images_url + (mode ? "/expand.gif" : "/collapse.gif");

document.getElementById("ShoutBox").style.display = mode ? "none" : "";

sb_current_header = mode;
}
</script>';

if (!empty($modSettings['anyPageShoutBox']) || isset($context['chat_isHome'])){
echo'
<div class="tborder" style="margin: 10px 0 10px 0;">
<div class="catbg" style="padding: 5px 15px 5px 10px;margin:0 auto;">
<a rel="nofollow" href="#" onclick="ajax_shoutBox_collapse(!sb_current_header)"><img id="ajax_shoutbox_collapse" src="', $settings['images_url'], empty($options['sb_collapsed']) ? '/collapse.gif' : '/expand.gif','" alt="*" style="margin-right: 5px;" /></a>', $txt['shoutBox'], '
</div>
<div id="ShoutBox"', empty($options['sb_collapsed']) ? '' : ' style="display: none;"', '>
', getShoutBoxContent() ,'
</div>
</div>';
}
}
}
}

[unplugged]

This part if(isset($board) && $board==1.0 || $board==33.0) {
shoutbox();
}
needs to go where you want the shoutbox to display (provided it's on the boards you have set up). In other words, if you want the shoutbox to be at the bottom of the page, then you need to put that code in an appropriate location at the bottom of the layout.

Just before the ?> at the very end of the file, you need to have this: function shoutbox()
{
   if (!empty($modSettings['enableShoutBox'])){
      if (allowedTo('shout_access')){
         // We'll have to use the cookie to remember the shoutBox header...
         if ($context['user']['is_guest'])
            $options['sb_collapsed'] = !empty($_COOKIE['sb_collapsed']);
           
         echo '
      <script language="JavaScript" type="text/javascript">
         var sb_current_header = ', empty($options['sb_collapsed']) ? 'false' : 'true', ';

         function ajax_shoutBox_collapse(mode)
         {';

         if ($context['user']['is_guest'])
            echo '
            document.cookie = "sb_collapsed=" + (mode ? 1 : 0);';
         else
            echo '
            smf_setThemeOption("sb_collapsed", mode ? 1 : 0, null, "', $context['session_id'], '");';

         echo '
            document.getElementById("ajax_shoutbox_collapse").src = smf_images_url + (mode ? "/expand.gif" : "/collapse.gif");

            document.getElementById("ShoutBox").style.display = mode ? "none" : "";

            sb_current_header = mode;
            }
      </script>';

         if (!empty($modSettings['anyPageShoutBox']) || isset($context['chat_isHome'])){
            echo'
      <div class="tborder" style="margin: 10px 0 10px 0;">
         <div class="catbg" style="padding: 5px 15px 5px 10px;margin:0 auto;">
            <a rel="nofollow" href="#" onclick="ajax_shoutBox_collapse(!sb_current_header)"><img id="ajax_shoutbox_collapse" src="', $settings['images_url'], empty($options['sb_collapsed']) ? '/collapse.gif' : '/expand.gif','" alt="*" style="margin-right: 5px;" /></a>', $txt['shoutBox'], '
         </div>
         <div id="ShoutBox"', empty($options['sb_collapsed']) ? '' : ' style="display: none;"', '>
         ', getShoutBoxContent() ,'
         </div>
      </div>';
         }
      }
   }
   }
which is the function itself.
« Next Edit: Tomorrow at 08:34:45 PM by SunKing »   <---- « someone stole my sig... :o »



llyon

I've installed AjaxChat (ajax_chat-0.8.2_SMF.zip)

And have then tried to install the integration mod - AjaxChat Integration_3.0..zip

However, the mod immediately responds with "The package you are trying to download or install is either corrupt or not compatible with this version of SMF." -  this is on SMF 2.0 Rc1-1

Anyone have any suggestions ?

mrtrc266

Quote from: allumius on June 11, 2009, 03:45:48 PM
Quote from: Youngiiie on June 11, 2009, 01:04:07 PM
Quote from: allumius on June 11, 2009, 12:43:36 PM
Well, i'm change my theme. Now i use BlackRainV2118
The chat work fine, but.... is posibble chat show only the last 10 lines? And the other whit scroll

I tink you need to find the guide by mrtrc266 - http://www.simplemachines.org/community/index.php?topic=257973.msg1981766#msg1981766

:)

Loads of info in there
i have read this thread, but i dont see the solution, and muy ShoutBox is very big and have now 35 lines!!!!!

I take it that you mean everytime you type a message the shoutbox just keeps getting bigger and bigger? If that it the case then you need to do this edit

Open yourforum/Themes/yourtheme/style.css

In the very first line of that file put
@import url(../../shoutBox/css/shoutbox.css);

mrtrc266

Quote from: llyon on June 12, 2009, 12:33:34 AM
I've installed AjaxChat (ajax_chat-0.8.2_SMF.zip)

And have then tried to install the integration mod - AjaxChat Integration_3.0..zip

However, the mod immediately responds with "The package you are trying to download or install is either corrupt or not compatible with this version of SMF." -  this is on SMF 2.0 Rc1-1

Anyone have any suggestions ?

Completely uninstall the ajax_chat-0.8.2_SMF.zip, remove all files and folders, drop all database tables and simply install this AJAX Chat Intergration Mod.

The Intergration Mod will install the chat for you and this will work for 1.1.9
http://www.simplemachines.org/community/index.php?topic=257973.msg2075610#msg2075610

mrtrc266

@ Chatter, glad you got the Smarter Chatbot sorted. I haven't had time to play with it but I plan on implementing on my site.

llyon

Well, that worked - I now have the shoutbox, but the chat is asking for username & password - but it will not accept the forum credentials.

fext

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

mrtrc266

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?

fext

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


Anyone?

Advertisement: