PunBB Resource

Your ultimate PunBB resource!

Keywords:

    (Extended)

You are not logged in.

#1 2006-06-29 15:34:09

pokemon_jojo
Member
Registered: 2005-04-28
Posts: 21
Website

PBB ChatBox 2.0

Code:

##

##

##        Mod title:  Poki BB ChatBox

##

##      Mod version:  2.0

##   Works on PunBB:  1.2.*

##     Release date:  2006-06-29

##           Author:  Pokemon_JOJO

##

##      Description:  Add a very simple AJAX ChatBox in punbb

##              Support Multi Languages

##              Support Multi Skins

##

##   Affected files:  none

##

##       Affects DB:  Yes

##

##            Notes:  No

##

##     Update Notes:  Yes, from PBB Chatbox 1.0

##

##       DISCLAIMER:  Please note that "mods" are not officially supported by

##                    PunBB. Installation of this modification is done at your

##                    own risk. Backup your forum database and any and all

##                    applicable files before proceeding.

##

##

Download here


ROSE Online FR - http://www.roseon-fr.com

Offline

 

#2 2006-07-02 11:32:59

falconflyz
Member
Registered: 2006-01-24
Posts: 54

Re: PBB ChatBox 2.0

Nice mod.Thank you
It would be interesting that you envisage the possibility for the admin to purge the chatbox from Admin menu, or even make a copy of the text before purging. (Same as "Empty log  Download log  View log" for mod "Log Forum Activity")

Regards

Offline

 

#3 2006-07-03 19:09:15

TheLastCubScout
New member
Registered: 2006-04-14
Posts: 5

Re: PBB ChatBox 2.0

Hi, thanks for this awesome mod! I really like it so far.

Is there a way to change the background color of the "info" text (making it darker), so that the messages are easier to find and read?

Edit: Also, my users are wanting it on the front page! Is there a way to do this?

Last edited by TheLastCubScout (2006-07-03 19:17:09)

Offline

 

#4 2006-07-03 19:35:03

TheLastCubScout
New member
Registered: 2006-04-14
Posts: 5

Re: PBB ChatBox 2.0

One more problem:

http://img395.imageshack.us/img395/3471/msg8pn.gif

See how the text at the bottom goes outside the lines? Is there a fix for this?

Offline

 

#5 2006-07-04 17:48:30

pokemon_jojo
Member
Registered: 2005-04-28
Posts: 21
Website

Re: PBB ChatBox 2.0

it's not a mod problem, it's a problem from your skin.


ROSE Online FR - http://www.roseon-fr.com

Offline

 

#6 2006-07-04 17:50:00

pokemon_jojo
Member
Registered: 2005-04-28
Posts: 21
Website

Re: PBB ChatBox 2.0

TheLastCubScout wrote:

Hi, thanks for this awesome mod! I really like it so far.

Is there a way to change the background color of the "info" text (making it darker), so that the messages are easier to find and read?

I don't know what you want to said ! What is for you the "info" text ?


ROSE Online FR - http://www.roseon-fr.com

Offline

 

#7 2006-07-04 20:53:30

yemgi
New member
From: Crawley, West Sussex
Registered: 2006-05-17
Posts: 8
Website

Re: PBB ChatBox 2.0

It is the line with the username and date wink


Tuning Tour is powered by PunBB

Offline

 

#8 2006-07-04 21:30:34

pokemon_jojo
Member
Registered: 2005-04-28
Posts: 21
Website

Re: PBB ChatBox 2.0

You can setup all your display message in the config : (Messages Display (parsing)).

Use HTML for setup ex. <span style="color: #FF0000;font-weight:bold;"><pun_username> - <pun_date></span><pun_admin><br /><pun_message>


ROSE Online FR - http://www.roseon-fr.com

Offline

 

#9 2006-07-07 10:58:32

Zedleouf
New member
Registered: 2005-05-20
Posts: 4

Re: PBB ChatBox 2.0

Hello everybody,

I just installed the Chatbox on my forum, but I wish to place it between Announce and Forums on the Index of my forum, is it possible?

Thanks,

Offline

 

#10 2006-07-17 18:15:09

TheLastCubScout
New member
Registered: 2006-04-14
Posts: 5

Re: PBB ChatBox 2.0

Hi,

My Finnish user gets this error with your mod:

Code:

Warning: main(./lang/Finnish/chatbox.php): failed to open stream: No such file or directory in /hermes/web03/b403/pow.mcarson/htdocs/aoiforum/chatbox.php on line 36

Fatal error: main(): Failed opening required './lang/Finnish/chatbox.php' (include_path='.:/usr/local/lib/php-4.4.2/lib/php') in /hermes/web03/b403/pow.mcarson/htdocs/aoiforum/chatbox.php on line 36

Any ideas on how to fix it? Thanks smile

Offline

 

#11 2006-07-18 11:53:35

pokemon_jojo
Member
Registered: 2005-04-28
Posts: 21
Website

Re: PBB ChatBox 2.0

it's simply, you have note made traduction of Finnish wink


ROSE Online FR - http://www.roseon-fr.com

Offline

 

#12 2006-07-26 11:33:12

pokemon_jojo
Member
Registered: 2005-04-28
Posts: 21
Website

Re: PBB ChatBox 2.0

@TheLastCubScout : if tou made a traduction, can you post it here please ? Thx


ROSE Online FR - http://www.roseon-fr.com

Offline

 

#13 2006-07-26 12:34:02

pokemon_jojo
Member
Registered: 2005-04-28
Posts: 21
Website

Re: PBB ChatBox 2.0

Zedleouf wrote:

Hello everybody,

I just installed the Chatbox on my forum, but I wish to place it between Announce and Forums on the Index of my forum, is it possible?

Thanks,

Now it's possible see the modifications here : "PBB Chatbox 2.0 on your index or where you want ! big_smile"


ROSE Online FR - http://www.roseon-fr.com

Offline

 

#14 2006-08-01 06:33:48

abekz
Guest

Re: PBB ChatBox 2.0

why i can't install this chatbox..

there's have message :

Warning: require(./include/common.php) [function.require]: failed to open stream: No such file or directory in C:\Program Files\xampp\htdocs\ChatBox\PBB ChatBox 2.0\install_mod.php on line 115

Fatal error: require() [function.require]: Failed opening required './include/common.php' (include_path='.;C:\Program Files\xampp\php\pear\') in C:\Program Files\xampp\htdocs\ChatBox\PBB ChatBox 2.0\install_mod.php on line 115

can i get common.php..??
thanks..

 

#15 2006-08-02 09:35:04

xxtubbyxx
Member
Registered: 2005-12-15
Posts: 168

Re: PBB ChatBox 2.0

in order to install this chatbox you must place install_mod.php in the root directory.....it seems to me that you have placed the install mod in an entirely different directory.


Coming to you soon: FatalGamers

Offline

 

#16 2006-08-19 11:31:19

Soulerman
Member
Registered: 2006-08-19
Posts: 18

Re: PBB ChatBox 2.0

This mod is great and works VERY ok wink

I made a little modifications and use it as a Shout Box smile
But I need help.

How and where should I change sth to make this box to show messages in reverse way.
e.g. when I write sth, the message will be show in the bottom of the box, but I want to show it in the upper segnent. So the most recent messages are sorted from up to down...

I will be really, really and more really appreshiated for such a thing smile

Offline

 

#17 2006-10-09 04:09:00

xxtubbyxx
Member
Registered: 2005-12-15
Posts: 168

Re: PBB ChatBox 2.0

ya same here this is how i would like to go about using the shoutbox but im not sure as of now.

anyways if you wish to implement the colored usergroups mod in to the chatbox then jsut do the following:

Open up chatbox.php

Find:

Code:

$result = $db->query('SELECT u.id, u.group_id, u.num_posts_chatbox, m.id AS m_id, m.poster_id, m.poster, m.poster_ip, m.poster_email, m.message, m.posted, g.g_id, g.g_title_chatbox FROM '.$db->prefix.'chatbox_msg AS m INNER JOIN '.$db->prefix.'users AS u ON u.id=m.poster_id INNER JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id ORDER BY m.posted DESC LIMIT '.$pun_config['cb_max_msg']) or error('Unable to fetch messages', __FILE__, __LINE__, $db->error());

Replace with:

Code:

$result = $db->query('SELECT u.id, u.group_id, u.num_posts_chatbox, m.id AS m_id, m.poster_id, m.poster, m.poster_ip, m.poster_email, m.message, m.posted, g.g_id, g.g_title_chatbox g.g_color FROM '.$db->prefix.'chatbox_msg AS m INNER JOIN '.$db->prefix.'users AS u ON u.id=m.poster_id INNER JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id ORDER BY m.posted DESC LIMIT '.$pun_config['cb_max_msg']) or error('Unable to fetch messages', __FILE__, __LINE__, $db->error());

Now Find:

Code:

if ($cur_msg['g_id'] != PUN_GUEST)
        $cur_msg_txt = str_replace('<pun_username>', '<a href="profile.php?id='.$cur_msg['id'].'">'.pun_htmlspecialchars($cur_msg['poster']).'</a>', $cur_msg_txt);
    else
        $cur_msg_txt = str_replace('<pun_username>', pun_htmlspecialchars($cur_msg['poster']), $cur_msg_txt);

and replace with:

Code:

if ($cur_msg['g_id'] != PUN_GUEST)
        $cur_msg_txt = str_replace('<pun_username>', '<a href="profile.php?id='.$cur_msg['id'].'">'<span style="color:<?php echo $cur_msg['g_color'] ?>">.pun_htmlspecialchars($cur_msg['poster']).'</span></a>', $cur_msg_txt);
    else
        $cur_msg_txt = str_replace('<pun_username>', pun_htmlspecialchars($cur_msg['poster']), $cur_msg_txt);

Thats it i believe. Now the colored usergroups modification should be applied to the chatbox.

Last edited by xxtubbyxx (2006-10-09 04:27:00)


Coming to you soon: FatalGamers

Offline

 

#18 2006-10-09 06:24:34

Infektid
Member
Registered: 2006-10-07
Posts: 30

Re: PBB ChatBox 2.0

^^nope Parse error: syntax error, unexpected T_STRING in chatbox.php on line 266

Last edited by Infektid (2006-10-09 06:26:13)


I can mod anything with punbb very good i just dont know what to make so if you have a request add ruinedscape@gmail.com n i'll surely finish your request within 3 days depending the mod your requesting.

Offline

 

#19 2006-10-09 12:20:27

xxtubbyxx
Member
Registered: 2005-12-15
Posts: 168

Re: PBB ChatBox 2.0

oops sorry about that lol should have looked at the file a little more carefully

follow these steps smile

Open up chatbox.php

find:

Code:

$result = $db->query('SELECT u.id, u.group_id, u.num_posts_chatbox, m.id AS m_id, m.poster_id, m.poster, m.poster_ip, m.poster_email, m.message, m.posted, g.g_id, g.g_title_chatbox FROM '.$db->prefix.'chatbox_msg AS m INNER JOIN '.$db->prefix.'users AS u ON u.id=m.poster_id INNER JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id ORDER BY m.posted DESC LIMIT '.$pun_config['cb_max_msg']) or error('Unable to fetch messages', __FILE__, __LINE__, $db->error());

replace with:

Code:

$result = $db->query('SELECT u.id, u.group_id, u.num_posts_chatbox, m.id AS m_id, m.poster_id, m.poster, m.poster_ip, m.poster_email, m.message, m.posted, g.g_id, g.g_title_chatbox, g.g_color FROM '.$db->prefix.'chatbox_msg AS m INNER JOIN '.$db->prefix.'users AS u ON u.id=m.poster_id INNER JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id ORDER BY m.posted DESC LIMIT '.$pun_config['cb_max_msg']) or error('Unable to fetch messages', __FILE__, __LINE__, $db->error());

find:

Code:

if ($cur_msg['g_id'] != PUN_GUEST)
        $cur_msg_txt = str_replace('<pun_username>', '<a href="profile.php?id='.$cur_msg['id'].'">'.pun_htmlspecialchars($cur_msg['poster']).'</a>', $cur_msg_txt);
    else
        $cur_msg_txt = str_replace('<pun_username>', pun_htmlspecialchars($cur_msg['poster']), $cur_msg_txt);

replace with:

Code:

if ($cur_msg['g_id'] != PUN_GUEST)
        $cur_msg_txt = str_replace('<pun_username>', '<a href="profile.php?id='.$cur_msg['id'].'"><span style="color: '.$cur_msg['g_color'].'">'.pun_htmlspecialchars($cur_msg['poster']).'</span></a>', $cur_msg_txt);
    else
        $cur_msg_txt = str_replace('<pun_username>', pun_htmlspecialchars($cur_msg['poster']), $cur_msg_txt);

find:

Code:

$result = $db->query('SELECT u.id, u.group_id, u.num_posts_chatbox, m.id AS m_id, m.poster_id, m.poster, m.poster_ip, m.poster_email, m.message, m.posted, g.g_id, g.g_title_chatbox FROM '.$db->prefix.'chatbox_msg AS m INNER JOIN '.$db->prefix.'users AS u ON u.id=m.poster_id INNER JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id ORDER BY m.posted DESC LIMIT '.$pun_config['cb_max_msg']) or error('Unable to fetch messages', __FILE__, __LINE__, $db->error());

replace with:

Code:

$result = $db->query('SELECT u.id, u.group_id, u.num_posts_chatbox, m.id AS m_id, m.poster_id, m.poster, m.poster_ip, m.poster_email, m.message, m.posted, g.g_id, g.g_title_chatbox, g.g_color FROM '.$db->prefix.'chatbox_msg AS m INNER JOIN '.$db->prefix.'users AS u ON u.id=m.poster_id INNER JOIN '.$db->prefix.'groups AS g ON g.g_id=u.group_id ORDER BY m.posted DESC LIMIT '.$pun_config['cb_max_msg']) or error('Unable to fetch messages', __FILE__, __LINE__, $db->error());

now find:

Code:

if ($cur_msg['g_id'] != PUN_GUEST)
        $cur_msg_txt = str_replace('<pun_username>', '<a href="profile.php?id='.$cur_msg['id'].'">'.pun_htmlspecialchars($cur_msg['poster']).'</a>', $cur_msg_txt);

and replace with:

Code:

if ($cur_msg['g_id'] != PUN_GUEST)
        $cur_msg_txt = str_replace('<pun_username>', '<a href="profile.php?id='.$cur_msg['id'].'"><span style="color: '.$cur_msg['g_color'].'">'.pun_htmlspecialchars($cur_msg['poster']).'</span></a>', $cur_msg_txt);

That should be it ive tested this myself.


Coming to you soon: FatalGamers

Offline

 

#20 2006-10-09 12:25:55

Soulerman
Member
Registered: 2006-08-19
Posts: 18

Re: PBB ChatBox 2.0

Hmmm... If someone know hot to change this messages order ... please write wink

Offline

 

#21 2006-10-09 12:44:45

xxtubbyxx
Member
Registered: 2005-12-15
Posts: 168

Re: PBB ChatBox 2.0

umm i believe my freind tyler has rearranged the messages order from down to up......ill check with him.


Coming to you soon: FatalGamers

Offline

 

#22 2006-10-09 13:24:39

xxtubbyxx
Member
Registered: 2005-12-15
Posts: 168

Re: PBB ChatBox 2.0

heres a list of things that i would like to see be added or improved protaining to this modification.

- No auto scroll ( If you direct this modification towards being a shoutbox instead of its own page then auto scroll will not be needed. )

- Opposite message listing ( Messages should be listed in the opposite direction. Meaning the newest messages on top. )

- Easy BBCode ( Easy bbcode would be a great add-on to this modification. )


- New form positioning ( Forms such as the "submit form" should be placed at the top of the chatbox not the bottom. This is so that the viewers can easily catch the new messages. )

- Maybe a chatbox statistics page ( Instead of displaying the statistics inside of the chatbox you can maybe have a main statistics page for the chatbox and then display how many chatbox posts a person has by displaying it somewhere in there profile and maybe even viewtopic.php. )

- Auto Refreshing when user shouts ( When a user shouts the chatbox should refresh and load the shouts instead of refreshing after a certain period of time. )

Well thats it i cant think of anything else atm.

Last edited by xxtubbyxx (2006-10-09 17:10:18)


Coming to you soon: FatalGamers

Offline

 

#23 2006-10-09 15:31:03

StevenBullen
Moderator
Registered: 2005-09-13
Posts: 300
Website

Re: PBB ChatBox 2.0

good ideas... some can be easily sorted yourself


Blog - Follow Me and FluxBB on Twitter

Offline

 

#24 2006-10-09 16:18:54

Soulerman
Member
Registered: 2006-08-19
Posts: 18

Re: PBB ChatBox 2.0

Smaller text/links ( I think that the chatbox should have smaller text and links so that more messages can fit on the screen with out having to scroll. )

I think that this can be easlity done by admin plugin ( just use html function ...) --> I use it and have smaller text, different colors etc wink

Opposite message listing ( Messages should be listed in the opposite direction. Meaning the newest messages on top. )

I will wait for this change big_smile

Offline

 

#25 2006-10-09 16:51:52

xxtubbyxx
Member
Registered: 2005-12-15
Posts: 168

Re: PBB ChatBox 2.0

alright forget about the text/link suggestion smile

Last edited by xxtubbyxx (2006-10-09 17:07:53)


Coming to you soon: FatalGamers

Offline

 

Board footer

Based on PunBB
© Copyright 2002–2005 Rickard Andersson

© Copyright 2004–2006 Kristoffer Jansson

User contributed files are property of their respective owners.