A place for MOD Authors to post and receive feedback on MODs still in development. No MODs within this forum should be used within a live environment!
by Handyman` » Mon May 21, 2007 11:18 pm
Classification: Add-on
phpBB Part: Forum
MOD Name: AJAX Chat
MOD Version: 2.0.0 Beta 8
Author: HandymanMOD Description: This Mod Adds AJAX Chat to your forum.
Demo: AJAX Chat MOD DemoUsers can chat without ever needing to reload the page.
Works with:Features:- AJAX Technology
- No page re-loading required
- Ability for Admins to delete posts in the Chat
- Shows who's online in the Chat
Language: English
Licence: GNU General Public License v2Screenshots: in action,
On main pageInstallation Level: Easy
Installation Time: ~3 Minutes
Format:
Download File: DownloadRoadmap- Add smilies button
- Show smilies in chat room
- Multiple Rooms (Progress = 25%)
- Report Post/Users
- Add Quote Button
- Enable Author Delete
- Private Rooms
- Send Chat Requests
- Reset Chat button
- Avatar Thumbnails with Fullsize Rollovers.
- Chat Logs
My Mod Roadmap:
http://startrekguide.com/forum/f100-mod ... html#p8507If you would like to be able to automatically remove all chat messages that can no longer be seen (if you don't want logs)
you can do this:
Handyman` wrote:open chat.php
Find
- Code: Select all
$sql = 'SELECT * FROM ' . CHAT_TABLE . ' ORDER BY message_id DESC';
$result = $db->sql_query_limit($sql, 25);
$rows = $db->sql_fetchrowset($result);
foreach ($rows as $row)
{
if ($count++ == 0)
{
$last_id = $row['message_id'];
}
$template->assign_block_vars('chatrow', array(
'MESSAGE_ID' => $row['message_id'],
'USERNAME_FULL' => clean_username(get_username_string('full', $row['user_id'], $row['username'], $row['user_colour'], $user->lang['GUEST'])),
'MESSAGE' => generate_text_for_display($row['message'], $row['bbcode_uid'], $row['bbcode_bitfield'], $row['bbcode_options']),
'TIME' => $user->format_date($row['time']),
'CLASS' => ($row['message_id'] % 2) ? 1 : 2,
));
}
$db->sql_freeresult($result);
Replace with
- Code: Select all
$sql = 'SELECT * FROM ' . CHAT_TABLE . ' ORDER BY message_id DESC';
$result = $db->sql_query_limit($sql, 25);
$rows = $db->sql_fetchrowset($result);
$db->sql_freeresult($result);
$delete_id = 0;
foreach ($rows as $row)
{
if ($count++ == 0)
{
$last_id = $row['message_id'];
}
$template->assign_block_vars('chatrow', array(
'MESSAGE_ID' => $row['message_id'],
'USERNAME_FULL' => get_username_string('full', $row['user_id'], $row['username'], $row['user_colour'], $user->lang['GUEST']),
'MESSAGE' => generate_text_for_display($row['message'], $row['bbcode_uid'], $row['bbcode_bitfield'], $row['bbcode_options']),
'TIME' => $user->format_date($row['time']),
'CLASS' => ($row['message_id'] % 2) ? 1 : 2,
));
$delete_id = $row['message_id'];
}
$sql = 'DELETE FROM ' . CHAT_TABLE . '
WHERE message_id < ' . $delete_id;
$db->sql_query($sql);
That will then delete all messages older than the last one displayed in the chat and will also only delete when you first view the chat.
Last edited by
Handyman` on Wed Aug 19, 2009 8:39 pm, edited 12 times in total.
-

Handyman`
- QA Team
-
- Posts: 1751
- Joined: Thu Feb 03, 2005 8:44 pm
-
by geoffreak » Mon May 21, 2007 11:20 pm
Wow, I didn't know your username was GroovePlugs here on phpbb.com

-
geoffreak
- Registered User
-
- Posts: 591
- Joined: Sat Feb 12, 2005 8:39 am
-
by eviL<3 » Mon May 21, 2007 11:21 pm
Great work there, handyman!
-

eviL<3
- Former Team Member
-
- Posts: 7479
- Joined: Fri Dec 16, 2005 12:23 pm
- Location: {postrow.POSTER_FROM}
-
by jerx » Mon May 21, 2007 11:31 pm
Wow, looks really nice! May I suggest a feature? Ability to show user' s avatars in the shoutbox. It uses up much resources and bandwidth, but my users love that and I think it helps keeping the site active.
One question though, why do I see a horizontal scroll bar?
-
jerx
- Registered User
-
- Posts: 167
- Joined: Fri Sep 02, 2005 4:27 am
by Handyman` » Mon May 21, 2007 11:35 pm
Yep… Handyman was taken here

Horizontal scroll bar… is that on my site or when you installed it on your site?
If it's on mine, which style are you viewing it in?
-

Handyman`
- QA Team
-
- Posts: 1751
- Joined: Thu Feb 03, 2005 8:44 pm
-
by jerx » Mon May 21, 2007 11:44 pm
It is on your site. It is the sniper pro style and I am viewing your site as a guest. To clarify the problem. I don' t mean a horizontal scroll bar at the bottom of my browser window. The shoutbox has the scrollbar in it, where the shouts are displayed.
-
jerx
- Registered User
-
- Posts: 167
- Joined: Fri Sep 02, 2005 4:27 am
by TimJBart » Mon May 21, 2007 11:46 pm
Is it possible to disable the memberlist on the right hand side? Looks good though

-

TimJBart
- Registered User
-
- Posts: 278
- Joined: Mon Jan 28, 2002 8:24 pm
by geoffreak » Tue May 22, 2007 12:35 am
TimJBart wrote:Is it possible to disable the memberlist on the right hand side? Looks good though

Just edit the file to display it how you wish

-
geoffreak
- Registered User
-
- Posts: 591
- Joined: Sat Feb 12, 2005 8:39 am
-
by Handyman` » Tue May 22, 2007 1:44 am
3Di wrote:Please provide a direct download link with no restriction. As per the Forum Rules. Thank you.

Thanks for the notice… link has been updated.
@Tim, you can change it however you like… it uses the style classes, so it would always match your style… if your style has them on the right, the chat will be on the right as well… but you can change it just by editing the stylesheet.
@jerx, check it out in subsilver and see if it's still there… append go to forum/chat.php?style=7
-

Handyman`
- QA Team
-
- Posts: 1751
- Joined: Thu Feb 03, 2005 8:44 pm
-
by mariotendo » Tue May 22, 2007 2:01 am
Very nice mod!
I was wondering if it was possible to use this on an ordinary web site, because I would really like to use a Shoutbox that uses the same database as my forum (I'm sure a few other people would like that feature as well).
-
mariotendo
- Registered User
-
- Posts: 14
- Joined: Thu Apr 12, 2007 7:04 pm
by Handyman` » Tue May 22, 2007 6:35 am
We just upgraded to RC1, so the demo is down for a bit until I re-install it tomorrow.
@mariotendo, you can't use it outside of phpbb because it uses the user->data to find your username and such and it also needs the template system… however, you can put it on any page you want that has the basic phpBB3 session and template info.
Very easy to do, just follow the instructions near the bottom of the install file (shows how to place it on the index page) follow those instructions for any page you want it on.
-

Handyman`
- QA Team
-
- Posts: 1751
- Joined: Thu Feb 03, 2005 8:44 pm
-
by Arm@nd » Tue May 22, 2007 3:43 pm
How long are kept the shouts ?
-
Arm@nd
- Registered User
-
- Posts: 12
- Joined: Mon Jan 10, 2005 5:10 pm
by jerx » Tue May 22, 2007 4:26 pm
GroovePlugs wrote:@jerx, check it out in subsilver and see if it's still there… append go to forum/chat.php?style=7
Looks the same - horizontal scrollbar. But there is a very long shout from yesterday (at 22.42).
-
jerx
- Registered User
-
- Posts: 167
- Joined: Fri Sep 02, 2005 4:27 am
by SmashingPilot » Tue May 22, 2007 6:00 pm
Is there now way to have the chat available from the main forum index. Currently, for people to be able to access the chat, they need to type in the address location for the chat. I would love to have the chat available to post in below all my current forums.
Do you know what I mean?? Is that possible?
Thanks.
-
SmashingPilot
- Registered User
-
- Posts: 9
- Joined: Wed May 09, 2007 7:09 pm
-
Return to [3.0.x] MODs in Development
Who is online
Users browsing this forum: *=Matt=*, Akbaio, Ask Jeeves [Bot], azzurri, BucsFan, DzoA, fs_unreal, jbarrouk, Lasse86, madmartyau, metropolis2k, MSNbot Media, netspy, poppertom69, posey and 79 guests