Go Back   vb.org Archive > vBulletin Modifications > Archive > vB.org Archives > vBulletin 2.x > vBulletin 2.x Full Releases

Reply
 
Thread Tools
vB Chatbox 1.2.4 Details »»
vB Chatbox 1.2.4
Version: 1.00, by p0s3id0n p0s3id0n is offline
Developer Last Online: Apr 2006 Show Printable Version Email this Page

Version: 2.3.x Rating:
Released: 08-24-2002 Last Update: Never Installs: 212
 
No support by the author.

What this hack does : Adds a box on top of your vB home page
where all members can chat/shout in an IRC like way, with all the
vB options added (smilies, vBcodes....)

I started this hack by modifying the shoutbox made by Doug
Tanner for phpnuke (i think).. And it went far far from his original
code. As far as i think he wouldn't recognize it .

I integrated it as far as i could with vB, and in the admin CP,
with every bit of it being possible to modify trough the admin
CP (prune, ban, censure...)...

SCREENSHOT

This hack has been tested and used by some people out
there in france .

1.2.4 changes :
Install problems with the mysql reserved words solved,
Uninstalling option added to the install script,
Possibility to automaticaly add the templates to the
templatesets you chose in the install script,
IE6 problem with divs solved,
timezoneoffset mod integrated,
text input limited to 255 characters.

1.2.3 changes :
security hole on the pruning of the admin part fixed.

1.2.2 changes :
templatesused var filled with all templates used by the
script in the shoutbox.php file and in the index.php file.
And chmod 777 made on the admin/shoutbox_config.php file
by the install script. Thanks to erwin

Name changed from shoutbox to chatbox, because some people
thought of this hack as related with TWT-commish's shoutbox...
no more excuses


Here is some sort of [high]FAQ[/high] from all the thread,
hope this helps, and prevents you from reading all that i just read :

[high]#----------------------------------------------------------#[/high]
Erwin : limit of smilies a person can post in the shoutbox.
This is to prevent smilie spamming : HERE
[high]#----------------------------------------------------------#[/high]
Erwin : Another tip for installers - instead of manually having to
ban users in the shoutbox, to automatically ban users who
you have already banned from the forums : HERE
[high]#----------------------------------------------------------#[/high]
For the shoutbox to be in a popup : HERE
[high]#----------------------------------------------------------#[/high]
To have 5 'shouts/chats' visible when the chatbox is reduced :
HERE
[high]#----------------------------------------------------------#[/high]
SpeedStreet : This simply creates a link for people to click on so
that they can easily view the 'Who's Online' page without
having to dig for it : HERE
[high]#----------------------------------------------------------#[/high]
ThoughtDiver: if you want the date format on the shout timestamps
to read Month/Day instead of Day/Month : HERE
[high]#----------------------------------------------------------#[/high]

Show Your Support

  • This modification may not be copied, reproduced or published elsewhere without author's permission.

Comments
  #22  
Old 08-26-2002, 04:34 AM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Update: It's all working beautifully at the moment. My members all love it - they like it better than TWT's hack.

In fact, the number of queries has been slashed by 90%. Why? Because now when members use the shoutbox to chat, all they are refreshing is the new shoubox.php file in an iframe, rather than refreshing the previous TWT's shoutbox.php file which included headers etc. as well as 20 queries and a whole lot of other stuff.

Thanks for the nice port. You can move this to the "Full Releases" once you update your install text files.
Reply With Quote
  #23  
Old 08-26-2002, 04:37 AM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Do you mind posting in this thread what I should do to upgrade to 1.2.2? Just tell me what to add to the templatesused bits in case I'm missing something.
Reply With Quote
  #24  
Old 08-26-2002, 04:41 AM
p0s3id0n p0s3id0n is offline
 
Join Date: Jun 2002
Posts: 55
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

here is the start of the shoutbox.php file upgraded to 1.2.2 :
PHP Code:
<?
error_reporting(7);

$templatesused = 'shoutbox,shoutbox_bit,shoutbox_bit_me,shoutbox_bit_vide,shoutbox_chat,shoutbox_fermee,shoutbox_frame,shoutbox_popup_smilbox,shoutbox_popup_smilboxbits,shoutbox_saisie,shoutbox_vbcodes';

require("./global.php");
require("./admin/shoutbox_config.php");
and here is the line i added just under the definition of the $templatesused var at the top of the index.php file of the root folder of the forum :
PHP Code:
$templatesused .= ',shoutbox,shoutbox_bit,shoutbox_bit_me,shoutbox_bit_vide,shoutbox_chat,shoutbox_fermee,shoutbox_frame,shoutbox_popup_smilbox,shoutbox_popup_smilboxbits,shoutbox_saisie,shoutbox_vbcodes'
For the chmod, since it's on the install script i supose you no longer need the modification .
Reply With Quote
  #25  
Old 08-26-2002, 04:51 AM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks.

Is there a way to use the member's timeoffset so that the time stamp works for the member's timezone?
Reply With Quote
  #26  
Old 08-26-2002, 04:57 AM
p0s3id0n p0s3id0n is offline
 
Join Date: Jun 2002
Posts: 55
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

errr, what a nice idea... but wouldn't it be a little bit confusing
if a shout under another shout didnt have timestamps
following each other ???

[high]* p0s3id0n notes the idea on a piece of paper for the 1.3 release .[/high]
Reply With Quote
  #27  
Old 08-26-2002, 05:00 AM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

No, no, all the timestamps will be offset to the user's timezone who is viewing the shoutbox. It would be good to have since I know when a member has posted according to my timezone, instead of the server timezone. TWT's shoutbox had this working fine using the - $timeoffset variable.
Reply With Quote
  #28  
Old 08-26-2002, 05:01 AM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I tried to implement this with your hack, but the way you parse the date and time is different...
Reply With Quote
  #29  
Old 08-26-2002, 05:28 AM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I've made it so that there is a limit of smilies a person can post in the shoutbox. This is to prevent smilie spamming.

In shoutbox.php, find:

PHP Code:
$sql "SELECT id FROM shoutbox WHERE date LIKE '".substr($date,0,10)."%' AND name='".$bbuserinfo['username']."' AND comment='".addslashes($message)."'"
Underneath, add:

PHP Code:
$parsey  bbcodeparse($message011);
                if (
countchar($parsey,"<img")>5) {
            eval(
"dooutput(\"".gettemplate('shoutbox_error')."\");");
                exit;
                } 
Then, add a new template called:

shoutbox_error

with these contents:

Code:
{htmldoctype}
<html>
<head>
$headinclude
</head>
<body bgcolor="$fondshoutbox">
<center><br><br><b><smallfont>NOTE: You are only allowed a maximum of 5 smilies. Please try again.</smallfont></b></center>
</body>
</html>
Done! You can change this line in shoutbox.php to increase or decrease the smilie limit, and edit the shoutbox_error template accordingly:

if (countchar($parsey,"<img")>5) {
Reply With Quote
  #30  
Old 08-26-2002, 05:33 AM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Now if only I can get the timeoffset thing to work... anyone has any clue?
Reply With Quote
  #31  
Old 08-26-2002, 05:59 AM
Erwin's Avatar
Erwin Erwin is offline
 
Join Date: Jan 2002
Posts: 7,604
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Another tip for installers - instead of manually having to ban users in the shoutbox, to automatically ban users who you have already banned from the forums, you can do this:

In shoutbox.php, find:

PHP Code:
if ((mysql_num_rows($result)){ 
Replace with:

PHP Code:
if (mysql_num_rows($result) OR $bbuserinfo[usergroupid]==8){ 
8 being the banned usergroupid.
Reply With Quote
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 03:24 AM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.07063 seconds
  • Memory Usage 2,322KB
  • Queries Executed 27 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)bbcode_code
  • (6)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)modsystem_post
  • (1)navbar
  • (6)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (11)post_thanks_box
  • (11)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (11)post_thanks_postbit_info
  • (10)postbit
  • (11)postbit_onlinestatus
  • (11)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.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/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete