View Single Post
  #2  
Old 26th August 2009, 14:49
Phogo's Avatar
Phogo Phogo is offline
VIP
 
Join Date: Jan 2008
United Kingdom
Posts: 902
Default
AJAX Shoutbox
based on YShout 4 (YShout 5: A PHP + AJAX Shoutbox)
tested with BTIT 1.4.4

Added Features:
+ Usernames with Links to Users Details
+ Users Groups Colors
+ Words Censor (uses tracker's badwords.txt)
+ Clickable Smileys
+ BBCodes
like:Code:
bold italic underline blue #ff0000 size 4 Impact
+ Dynamic Online Counter (http://www.programming-designs.com/p...scripts/item/5)
+ Time Offset
+ Guest Access (option in YShout CP)

Upload (copy) the files from the attached archive to your web server.
You should have the following file structure:
Code:
addons/js/
addons/yshout/
blocks/
yshout_block.php

Set read-write permissions on the addons/yshout/logs/ directory and *.txt files inside it.

include/functions.php
find:
PHP Code:
setcookie("pass"$passhash$expires"/"); 
add below:
PHP Code:
setcookie("yNickname"""0x7fffffff"/"); 
find:
PHP Code:
setcookie("pass"""0x7fffffff"/"); 
add below:
PHP Code:
setcookie("yNickname"""0x7fffffff"/"); 
find:
PHP Code:
print("<link rel=\"stylesheet\" href=$style type=\"text/css\" />");add below
Code:
PHP Code:
$res = @mysql_query("SELECT * FROM blocks WHERE content = 'yshout' AND status = 1");
$num = @mysql_num_rows($res);
if (
$num == && eregi('index.php'$_SERVER['PHP_SELF']))
    echo 
'<script type="text/javascript" src="./addons/js/jquery.js"></script>
<script type="text/javascript" src="./addons/js/spy.js"></script>
<script type="text/javascript" src="./addons/yshout/js/yshout.js"></script>
<link rel="stylesheet" type="text/css" href="./addons/yshout/css/yshout.css" />'

language/english.php
find:
PHP Code:
?> 
add above:Code:
PHP Code:
define('_YSHOUT''YShout');
define('_YSHOUT_MESSAGE''Message Text');
define('_YSHOUT_SUBMIT''Shout!');
define('_YSHOUT_CONTROL_PANEL''YShout Control Panel');
define('_YSHOUT_ADMIN_CP''Admin CP');
define('_YSHOUT_HISTORY_VIEWER''YShout History Viewer');
define('_YSHOUT_HISTORY''History');
define('_YSHOUT_LOGIN''You must be logged in to use the shoutbox!');
define('_YSHOUT_LOG''Log');
define('_YSHOUT_VIEWING_LOG''Viewing Log #');
define('_YSHOUT_LOG_EMPTY''This log does not contain any shouts.');
define('_DOC_PEOPLE_ONLINE''People Online');
define('_LANGUAGE''english');//name of the current file (without extension) 
Run the following SQL query:
PHP Code:
INSERT INTO blocks VALUES (20'yshout''c'01); 
Attached Thumbnails
yshout_block.png  
Attached Files
File Type: zip yshout_block.zip (82.2 KB, 76 views)
Reply With Quote