phpfreechat-svn Mailing List for phpFreeChat (Page 22)
Status: Beta
Brought to you by:
kerphi
You can subscribe to this list here.
2006 |
Jan
|
Feb
(2) |
Mar
|
Apr
(61) |
May
(56) |
Jun
(96) |
Jul
(23) |
Aug
(62) |
Sep
(76) |
Oct
(48) |
Nov
(28) |
Dec
(28) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(31) |
Feb
(40) |
Mar
(29) |
Apr
(11) |
May
(6) |
Jun
(18) |
Jul
(18) |
Aug
(108) |
Sep
(24) |
Oct
(6) |
Nov
(21) |
Dec
|
2008 |
Jan
|
Feb
(1) |
Mar
(16) |
Apr
|
May
(3) |
Jun
|
Jul
(7) |
Aug
(1) |
Sep
(3) |
Oct
|
Nov
(3) |
Dec
(2) |
2009 |
Jan
(2) |
Feb
|
Mar
(2) |
Apr
(3) |
May
|
Jun
|
Jul
|
Aug
(1) |
Sep
(1) |
Oct
(1) |
Nov
|
Dec
(1) |
2010 |
Jan
(2) |
Feb
|
Mar
|
Apr
(6) |
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
2018 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <ke...@us...> - 2006-09-08 21:23:08
|
Revision: 742 http://svn.sourceforge.net/phpfreechat/?rev=742&view=rev Author: kerphi Date: 2006-09-08 14:23:04 -0700 (Fri, 08 Sep 2006) Log Message: ----------- Bug fix: the nick should not be changed before the connect step or it will block periodic refresh Modified Paths: -------------- trunk/src/proxys/checknickchange.class.php Modified: trunk/src/proxys/checknickchange.class.php =================================================================== --- trunk/src/proxys/checknickchange.class.php 2006-09-08 20:58:59 UTC (rev 741) +++ trunk/src/proxys/checknickchange.class.php 2006-09-08 21:23:04 UTC (rev 742) @@ -37,11 +37,11 @@ $sender = $p["sender"]; $recipient = $p["recipient"]; $recipientid = $p["recipientid"]; - + $owner = isset($p["owner"]) ? $p["owner"] : ''; $c =& $this->c; $u =& $this->u; - if ( $this->name == "nick") + if ( $this->name == 'nick' ) { $newnick = phpFreeChat::FilterNickname($param); $oldnick = $u->nick; @@ -60,7 +60,7 @@ $u->nick != "" && $param != $u->nick && $c->frozen_nick == true && - $p["owner"] != "checknickchange" ) + $owner != $this->proxyname ) { $msg = _pfc("You are not allowed to change your nickname"); $xml_reponse->addScript("pfc.handleResponse('".$this->proxyname."', 'nick', '".addslashes($msg)."');"); @@ -103,23 +103,21 @@ } // allow nick changes only from the parameters array (server side) - if ($c->frozen_nick == true && + if ($this->name != 'connect' && // don't check anything on the connect process or it could block the periodic refresh + $c->frozen_nick == true && $u->nick != $c->nick && $c->nick != "" && // don't change the nickname to empty or the asknick popup will loop indefinatly - $p["owner"] != "checknickchange") + $owner != $this->proxyname) { // change the user nickname $cmdp = $p; $cmdp["param"] = $c->nick; - $cmdp["owner"] = "checknickchange"; + $cmdp["owner"] = $this->proxyname; $cmd =& pfcCommand::Factory("nick"); $cmd->run($xml_reponse, $cmdp); return; } - - - // forward the command to the next proxy or to the final command $this->next->run($xml_reponse, $p); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-08 20:59:09
|
Revision: 741 http://svn.sourceforge.net/phpfreechat/?rev=741&view=rev Author: kerphi Date: 2006-09-08 13:58:59 -0700 (Fri, 08 Sep 2006) Log Message: ----------- [en] New checktimeout proxy used to disconnect timeouted users before playing a command. [fr] Nouveau proxy checktimeout dont la fonction est de d?\195?\169connecter les utilisateurs qui sont en timeout. Modified Paths: -------------- trunk/src/commands/connect.class.php trunk/src/commands/getonlinenick.class.php trunk/src/commands/update.class.php trunk/src/pfcglobalconfig.class.php Added Paths: ----------- trunk/src/proxys/checktimeout.class.php Modified: trunk/src/commands/connect.class.php =================================================================== --- trunk/src/commands/connect.class.php 2006-09-08 20:56:24 UTC (rev 740) +++ trunk/src/commands/connect.class.php 2006-09-08 20:58:59 UTC (rev 741) @@ -14,10 +14,7 @@ $c =& $this->c; $u =& $this->u; - - // disconnect last connected users from the server if necessary $container =& $c->getContainerInstance(); - $disconnected_users = $container->removeObsoleteNick(NULL, $c->timeout); // reset the message id indicator (see getnewmsg.class.php) // i.e. be ready to re-get all last posted messages Modified: trunk/src/commands/getonlinenick.class.php =================================================================== --- trunk/src/commands/getonlinenick.class.php 2006-09-08 20:56:24 UTC (rev 740) +++ trunk/src/commands/getonlinenick.class.php 2006-09-08 20:58:59 UTC (rev 741) @@ -14,18 +14,6 @@ $c =& $this->c; $container =& $c->getContainerInstance(); - - // take care to disconnect timeouted users on this channel - $disconnected_users = $container->removeObsoleteNick($recipient,$c->timeout); - if (isset($disconnected_users["nick"])) - foreach ($disconnected_users["nick"] as $n) - { - $cmdp = $p; - $cmdp["param"] = _pfc("%s quit (timeout)", $n); - $cmdp["flag"] = 2; - $cmd =& pfcCommand::Factory("notice"); - $cmd->run($xml_reponse, $cmdp); - } // get the cached nickname list $nicklist_sid = $c->prefix."nicklist_".$c->getId()."_".$clientid."_".$recipientid; Modified: trunk/src/commands/update.class.php =================================================================== --- trunk/src/commands/update.class.php 2006-09-08 20:56:24 UTC (rev 740) +++ trunk/src/commands/update.class.php 2006-09-08 20:58:59 UTC (rev 741) @@ -67,19 +67,7 @@ $cmd->run($xml_reponse, $cmdp); } - // take care to disconnect timeouted users on the server - $container =& $c->getContainerInstance(); - $disconnected_users = $container->removeObsoleteNick(NULL,$c->timeout); - // if whould be possible to echo these disconnected users on a server tab - // server tab is not yet available so I just commente the code - // foreach ($disconnected_users as $u) - // { - // $cmd =& pfcCommand::Factory("notice"); - // $cmd->run($xml_reponse, $clientid, _pfc("%s quit (timeout)",$u), $sender, $recipient, $recipientid, 2); - // } - - // do not send a response in order to save some bandwidth - // $xml_reponse->addScript("pfc.handleResponse('update', 'ok', '');"); + $xml_reponse->addScript("pfc.handleResponse('update', 'ok', '');"); } else $xml_reponse->addScript("pfc.handleResponse('update', 'ko', '');"); Modified: trunk/src/pfcglobalconfig.class.php =================================================================== --- trunk/src/pfcglobalconfig.class.php 2006-09-08 20:56:24 UTC (rev 740) +++ trunk/src/pfcglobalconfig.class.php 2006-09-08 20:58:59 UTC (rev 741) @@ -41,7 +41,7 @@ var $lockurl = "http://www.phpfreechat.net"; // this is the url where the users must be redirected when the chat is locked // these parameters are static (cached) - var $proxys = array("lock", "auth", "checknickchange", "noflood", "censor", "log"); + var $proxys = array("lock", "checktimeout", "checknickchange", "auth", "noflood", "censor", "log"); var $proxys_cfg = array("auth" => array(), "noflood" => array("limit"=>10,"delay"=>5), "censor" => array("words"=>array("fuck","sex","bitch"),"replaceby"=>"*"), Added: trunk/src/proxys/checktimeout.class.php =================================================================== --- trunk/src/proxys/checktimeout.class.php (rev 0) +++ trunk/src/proxys/checktimeout.class.php 2006-09-08 20:58:59 UTC (rev 741) @@ -0,0 +1,74 @@ +<?php +/** + * checktimeout.class.php + * + * Copyright © 2006 Stephane Gully <ste...@gm...> + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, 51 Franklin St, Fifth Floor, + * Boston, MA 02110-1301 USA + */ +require_once dirname(__FILE__)."/../pfci18n.class.php"; +require_once dirname(__FILE__)."/../pfcuserconfig.class.php"; +require_once dirname(__FILE__)."/../pfcproxycommand.class.php"; + +/** + * pfcProxyCommand_checktimeout + * this command disconnect obsolete users (timouted) + * an obsolete user is an user which didn't update his stats since more than 20 seconds (timeout value) + * @author Stephane Gully <ste...@gm...> + */ +class pfcProxyCommand_checktimeout extends pfcProxyCommand +{ + function run(&$xml_reponse, $p) + { + $clientid = $p["clientid"]; + $param = $p["param"]; + $sender = $p["sender"]; + $recipient = $p["recipient"]; + $recipientid = $p["recipientid"]; + + $c =& $this->c; + $u =& $this->u; + + if ( $this->name == 'update' || + $this->name == 'connect' ) + { + // disconnect users from the server pool + $container =& $c->getContainerInstance(); + $disconnected_users = $container->removeObsoleteNick(NULL,$c->timeout); + } + + if ( $this->name == 'getonlinenick' ) + { + // disconnect users from specific channels + $container =& $c->getContainerInstance(); + $disconnected_users = $container->removeObsoleteNick($recipient,$c->timeout); + if (isset($disconnected_users["nick"])) + foreach ($disconnected_users["nick"] as $n) + { + $cmdp = $p; + $cmdp["param"] = _pfc("%s quit (timeout)", $n); + $cmdp["flag"] = 2; + $cmd =& pfcCommand::Factory("notice"); + $cmd->run($xml_reponse, $cmdp); + } + } + + // forward the command to the next proxy or to the final command + $this->next->run($xml_reponse, $p); + } +} + +?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-08 20:56:30
|
Revision: 740 http://svn.sourceforge.net/phpfreechat/?rev=740&view=rev Author: kerphi Date: 2006-09-08 13:56:24 -0700 (Fri, 08 Sep 2006) Log Message: ----------- code cleaning Modified Paths: -------------- trunk/src/proxys/checknickchange.class.php Modified: trunk/src/proxys/checknickchange.class.php =================================================================== --- trunk/src/proxys/checknickchange.class.php 2006-09-08 20:55:53 UTC (rev 739) +++ trunk/src/proxys/checknickchange.class.php 2006-09-08 20:56:24 UTC (rev 740) @@ -50,7 +50,7 @@ { $xml_reponse->addScript("pfc.handleResponse('nick', 'notchanged', '".addslashes($newnick)."');"); if ($c->debug) - pxlog("/nick ".$newnick." (user just reloded the page so let him keep his nickname without any warnings -> nickid=".$newnickid.")", "chat", $c->getId()); + pxlog("/nick ".$newnick." (user just reloded the page so let him keep his nickname without any warnings)", "chat", $c->getId()); return; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-08 20:56:06
|
Revision: 739 http://svn.sourceforge.net/phpfreechat/?rev=739&view=rev Author: kerphi Date: 2006-09-08 13:55:53 -0700 (Fri, 08 Sep 2006) Log Message: ----------- code cleaning (php notice) Modified Paths: -------------- trunk/debug/log.php trunk/lib/utf8/utf8_substr.php trunk/src/commands/getnewmsg.class.php Modified: trunk/debug/log.php =================================================================== --- trunk/debug/log.php 2006-09-08 20:54:35 UTC (rev 738) +++ trunk/debug/log.php 2006-09-08 20:55:53 UTC (rev 739) @@ -6,9 +6,9 @@ $filename = dirname(__FILE__)."/../data/private/debug".$section."_".$id.".log"; if (!file_exists($filename)) @touch($filename); - $fp = fopen($filename, 'a'); - fwrite($fp, "[".$id."] ".date("Y/m/d H:i:s - ").$msg."\n"); - fclose($fp); + $fp = @fopen($filename, 'a'); + @fwrite($fp, "[".$id."] ".date("Y/m/d H:i:s - ").$msg."\n"); + @fclose($fp); } ?> Modified: trunk/lib/utf8/utf8_substr.php =================================================================== --- trunk/lib/utf8/utf8_substr.php 2006-09-08 20:54:35 UTC (rev 738) +++ trunk/lib/utf8/utf8_substr.php 2006-09-08 20:55:53 UTC (rev 739) @@ -17,7 +17,7 @@ function utf8_substr($str,$start,$len=null) { if (!strcmp($len,'0')) return ''; - $byte_start = utf8_char2byte_pos($str,$start); + $byte_start = @utf8_char2byte_pos($str,$start); if ($byte_start === false) { if ($start > 0) { return false; // $start outside string length @@ -29,7 +29,7 @@ $str = substr($str,$byte_start); if ($len!=null) { - $byte_end = utf8_char2byte_pos($str,$len); + $byte_end = @utf8_char2byte_pos($str,$len); if ($byte_end === false) // $len outside actual string length return $len<0 ? '' : $str; // When length is less than zero and exceeds, then we return blank string. else Modified: trunk/src/commands/getnewmsg.class.php =================================================================== --- trunk/src/commands/getnewmsg.class.php 2006-09-08 20:54:35 UTC (rev 738) +++ trunk/src/commands/getnewmsg.class.php 2006-09-08 20:55:53 UTC (rev 739) @@ -44,6 +44,7 @@ } // check if this is the first time you get messages $oldmsg_sid = $c->prefix."oldmsg_".$c->getId()."_".$clientid."_".$recipientid; + $oldmsg = false; if (isset($_SESSION[$oldmsg_sid])) { unset($_SESSION[$oldmsg_sid]); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-08 20:54:40
|
Revision: 738 http://svn.sourceforge.net/phpfreechat/?rev=738&view=rev Author: kerphi Date: 2006-09-08 13:54:35 -0700 (Fri, 08 Sep 2006) Log Message: ----------- code cleaning (notice) Modified Paths: -------------- trunk/src/commands/rehash.class.php Modified: trunk/src/commands/rehash.class.php =================================================================== --- trunk/src/commands/rehash.class.php 2006-09-08 20:53:29 UTC (rev 737) +++ trunk/src/commands/rehash.class.php 2006-09-08 20:54:35 UTC (rev 738) @@ -25,7 +25,7 @@ // the right way is to wait for the next page reload and the new parameters will be taken into account $destroyed = $c->destroyCache(); - if ($destroyed && $synchro) + if ($destroyed) $xml_reponse->addScript("pfc.handleResponse('".$this->name."', 'ko', '');"); else $xml_reponse->addScript("pfc.handleResponse('".$this->name."', 'ok', '');"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-08 20:53:37
|
Revision: 737 http://svn.sourceforge.net/phpfreechat/?rev=737&view=rev Author: kerphi Date: 2006-09-08 13:53:29 -0700 (Fri, 08 Sep 2006) Log Message: ----------- code cleaning Modified Paths: -------------- trunk/src/containers/file.class.php Modified: trunk/src/containers/file.class.php =================================================================== --- trunk/src/containers/file.class.php 2006-09-06 06:53:04 UTC (rev 736) +++ trunk/src/containers/file.class.php 2006-09-08 20:53:29 UTC (rev 737) @@ -671,7 +671,8 @@ $ret = @unlink($filename); // remove the cached data - unset($this->_meta[$enc_type][$enc_subtype][$enc_key]); + if (isset($this->_meta[$enc_type][$enc_subtype][$enc_key])) + unset($this->_meta[$enc_type][$enc_subtype][$enc_key]); } return $ret; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-06 06:53:13
|
Revision: 736 http://svn.sourceforge.net/phpfreechat/?rev=736&view=rev Author: kerphi Date: 2006-09-05 23:53:04 -0700 (Tue, 05 Sep 2006) Log Message: ----------- [en] Bug fix: the width parameters was broken [fr] Bug fix : the param?\195?\168tre width ne fonctionnait pas Modified Paths: -------------- trunk/demo/demo2_simple_with_params.php trunk/src/phpfreechat.class.php Modified: trunk/demo/demo2_simple_with_params.php =================================================================== --- trunk/demo/demo2_simple_with_params.php 2006-09-05 19:24:47 UTC (rev 735) +++ trunk/demo/demo2_simple_with_params.php 2006-09-06 06:53:04 UTC (rev 736) @@ -38,9 +38,7 @@ <body> - <div style="width: 800px;"> - <?php $chat->printChat(); ?> - </div> + <?php $chat->printChat(); ?> <?php // print the current file Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-09-05 19:24:47 UTC (rev 735) +++ trunk/src/phpfreechat.class.php 2006-09-06 06:53:04 UTC (rev 736) @@ -178,7 +178,7 @@ $u =& pfcUserConfig::Instance(); - $output = "<div id=\"pfc_container\"".($c->width != "" ? "style=\"width:".$c->width."\"": "").">"; + $output = "<div id=\"pfc_container\"".($c->width != "" ? " style=\"width:".$c->width."\"": "").">"; // Please do not remove these lines, // or keep a backling to http://www.phpfreechat on your partner page This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-05 19:24:59
|
Revision: 735 http://svn.sourceforge.net/phpfreechat/?rev=735&view=rev Author: kerphi Date: 2006-09-05 12:24:47 -0700 (Tue, 05 Sep 2006) Log Message: ----------- tag de la 1.0-beta5 Added Paths: ----------- tags/1.0-beta5/ Copied: tags/1.0-beta5 (from rev 733, trunk) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-05 16:24:35
|
Revision: 734 http://svn.sourceforge.net/phpfreechat/?rev=734&view=rev Author: kerphi Date: 2006-09-05 09:24:23 -0700 (Tue, 05 Sep 2006) Log Message: ----------- [en] - Makes possible to use frozen_nick with a empty nick parameter. So it's possible to choose the nick at beginning of the session then it's impossible to change it. [fr] - Rend possible l'utilisation de frozen_nick avec un pseudonyme vide. Ainsi c'est possible de choisir son pseudo a la premi?\195?\168re connexion et ensuite c'est impossible de le changer. [en] - Make possible to change dynamicaly the user nickname using the parameter array (however, frozen_nick must be on) [fr] - On peut maintenant forcer un utilisateur ?\195?\160 changer de pseudo dynamiquement (ex: si l'utilisateur change de pseudo dans le syst?\195?\168me d'authentification hote). Pour cela il suffit d'assigner un nouveau nick dans les parametres en plein milieur de l'execution. Bien sur frozen_nick doit ?\195?\170tre activ?\195?\169! Modified Paths: -------------- trunk/src/client/chat.js.tpl.php trunk/src/client/pfcclient.js trunk/src/commands/nick.class.php trunk/src/pfcglobalconfig.class.php trunk/src/pfcuserconfig.class.php trunk/src/phpfreechat.class.php trunk/src/proxys/auth.class.php Added Paths: ----------- trunk/src/proxys/checknickchange.class.php Modified: trunk/src/client/chat.js.tpl.php =================================================================== --- trunk/src/client/chat.js.tpl.php 2006-09-04 20:41:46 UTC (rev 733) +++ trunk/src/client/chat.js.tpl.php 2006-09-05 16:24:23 UTC (rev 734) @@ -1,5 +1,6 @@ +<?php $nick = $u->nick != "" ? addslashes($u->nick) : addslashes($c->nick); ?> +var pfc_nickname = '<?php echo ($GLOBALS["output_encoding"]=="UTF-8" ? $nick : iconv("UTF-8", $GLOBALS["output_encoding"],$nick)); ?>'; var pfc_version = '<?php echo $version; ?>'; -var pfc_nickname = '<?php echo ($GLOBALS["output_encoding"]=="UTF-8" ? addslashes($u->nick) : iconv("UTF-8", $GLOBALS["output_encoding"],addslashes($u->nick))); ?>'; var pfc_clientid = '<?php echo md5(uniqid(rand(), true)); ?>'; var pfc_title = '<?php echo addslashes($title); ?>'; var pfc_refresh_delay = <?php echo $refresh_delay; ?>; @@ -78,6 +79,7 @@ "Enter the text to format", // _pfc "Configuration has been rehashed", // _pfc "A problem occurs during rehash", // _pfc + "Choosen nickname is allready used", //_pfc ); foreach($labels_to_load as $l) { Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-09-04 20:41:46 UTC (rev 733) +++ trunk/src/client/pfcclient.js 2006-09-05 16:24:23 UTC (rev 734) @@ -306,7 +306,7 @@ } else if (resp == "isused") { - this.askNick(param); + this.displayMsg( cmd, this.res.getLabel('Choosen nickname is allready used') ); } else alert(cmd + "-"+resp+"-"+param); @@ -374,6 +374,10 @@ { this.displayMsg( cmd, param ); } + else if (cmd == "checknickchange") + { + this.displayMsg( cmd, param ); + } else alert(cmd + "-"+resp+"-"+param); }, Modified: trunk/src/commands/nick.class.php =================================================================== --- trunk/src/commands/nick.class.php 2006-09-04 20:41:46 UTC (rev 733) +++ trunk/src/commands/nick.class.php 2006-09-05 16:24:23 UTC (rev 734) @@ -31,111 +31,64 @@ $newnick = phpFreeChat::FilterNickname($param); $oldnick = $u->nick; - if ($c->debug) pxlog("/nick ".$newnick, "chat", $c->getId()); - $container =& $c->getContainerInstance(); $newnickid = $container->getNickId($newnick); - $oldnickid = $container->getNickId($u->nick); + $oldnickid = $container->getNickId($oldnick); - // now check unsensitive case - // 'BoB' and 'bob' must be considered same nicknames - $nick_in_use = false; - $online_users = $container->getOnlineNick(NULL); - if (isset($online_users["nickid"])) - foreach($online_users["nickid"] as $nid) - { - if (preg_match("/^".preg_quote($container->getNickname($nid))."$/i",$newnick)) - { - // the nick match - // just allow the owner to change his capitalised letters - if ($nid != $oldnickid) - $nick_in_use = true; - } - } + if ($c->debug) pxlog("/nick ".$newnick, "chat", $c->getId()); - if ( $newnickid == "undefined" && !$nick_in_use ) + // new nickname is undefined (not used) and + // current nickname (oldnick) is mine and + // oldnick is different from new nick + // -> this is a nickname change + if ($oldnickid == $u->nickid && + $oldnick != $newnick && $oldnick != "") { - // new nickname is undefined (not used) and - // current nickname (oldnick) is mine and - // oldnick is different from new nick - // -> this is a nickname change - if ($oldnickid == $u->nickid && - $oldnick != $newnick && $oldnick != "") - { - // really change the nick (rename it) - $container->changeNick($newnick, $oldnick); - $u->nick = $newnick; - $u->saveInCache(); + // really change the nick (rename it) + $container->changeNick($newnick, $oldnick); + $u->nick = $newnick; + $u->saveInCache(); - // notify all the joined channels/privmsg - $cmdp = $p; - $cmdp["param"] = _pfc("%s changes his nickname to %s",$oldnick,$newnick); - $cmdp["flag"] = 1; - $cmd =& pfcCommand::Factory("notice"); - foreach($u->channels as $id => $chan) - { - $cmdp["recipient"] = $chan["recipient"]; - $cmdp["recipientid"] = $id; - $cmd->run($xml_reponse, $cmdp); - } - foreach( $u->privmsg as $id => $pv ) - { - $cmdp["recipient"] = $pv["recipient"]; - $cmdp["recipientid"] = $id; - $cmd->run($xml_reponse, $cmdp); - } - $xml_reponse->addScript("pfc.handleResponse('nick', 'changed', '".addslashes($newnick)."');"); + // notify all the joined channels/privmsg + $cmdp = $p; + $cmdp["param"] = _pfc("%s changes his nickname to %s",$oldnick,$newnick); + $cmdp["flag"] = 1; + $cmd =& pfcCommand::Factory("notice"); + foreach($u->channels as $id => $chan) + { + $cmdp["recipient"] = $chan["recipient"]; + $cmdp["recipientid"] = $id; + $cmd->run($xml_reponse, $cmdp); } - - // new nickname is undefined (not used) and - // current nickname (oldnick) is not mine or is undefined - // -> this is a first connection - if ($oldnickid != $u->nickid) + foreach( $u->privmsg as $id => $pv ) { - // this is a first connection (create the nickname) - $container->createNick(NULL, $newnick, $u->nickid); - foreach($u->channels as $chan) - $container->createNick($chan["recipient"], $newnick, $u->nickid); - foreach($u->privmsg as $pv) - $container->createNick($pv["recipient"], $newnick, $u->nickid); - $u->nick = $newnick; - $u->active = true; - $u->saveInCache(); - - $xml_reponse->addScript("pfc.handleResponse('nick', 'connected', '".addslashes($newnick)."');"); - - if ($c->debug) - pxlog("/nick ".$newnick." (first connection, oldnick=".$oldnick.")", "chat", $c->getId()); + $cmdp["recipient"] = $pv["recipient"]; + $cmdp["recipientid"] = $id; + $cmd->run($xml_reponse, $cmdp); } - - // force the handle field to be uptodate - // $xml_reponse->addAssign($c->prefix."handle", "value", $newnick); - //$xml_reponse->addScript("$('".$c->prefix."words').focus();"); - + $xml_reponse->addScript("pfc.handleResponse('nick', 'changed', '".addslashes($newnick)."');"); } - else if ($newnickid == $u->nickid) + + // new nickname is undefined (not used) and + // current nickname (oldnick) is not mine or is undefined + // -> this is a first connection + if ($oldnickid != $u->nickid) { - // user didn't change his nickname - //$xml_reponse->addAssign($c->prefix."handle", "value", $newnick); - $xml_reponse->addScript("pfc.handleResponse('nick', 'notchanged', '".addslashes($newnick)."');"); + // this is a first connection (create the nickname) + $container->createNick(NULL, $newnick, $u->nickid); + foreach($u->channels as $chan) + $container->createNick($chan["recipient"], $newnick, $u->nickid); + foreach($u->privmsg as $pv) + $container->createNick($pv["recipient"], $newnick, $u->nickid); + $u->nick = $newnick; + $u->active = true; + $u->saveInCache(); + $xml_reponse->addScript("pfc.handleResponse('nick', 'connected', '".addslashes($newnick)."');"); + if ($c->debug) - pxlog("/nick ".$newnick." (user just reloded the page so let him keep his nickname without any warnings -> nickid=".$newnickid.")", "chat", $c->getId()); + pxlog("/nick ".$newnick." (first connection, oldnick=".$oldnick.")", "chat", $c->getId()); } - else - { - // the wanted nick is allready used, just ask again the user - //$cmd =& pfcCommand::Factory("asknick"); - //$cmd->run($xml_reponse, $clientid, $newnick, $sender, $recipient); - - $xml_reponse->addScript("pfc.handleResponse('nick', 'isused', '".addslashes($newnick)."');"); - - if ($c->debug) - pxlog("/nick ".$newnick." (wanted nick is allready in use -> wantednickid=".$newnickid.")", "chat", $c->getId()); - } - - // refresh users info on client side - //$xml_reponse->addScript("pfc.nickname = '".$u->nick."';"); } } Modified: trunk/src/pfcglobalconfig.class.php =================================================================== --- trunk/src/pfcglobalconfig.class.php 2006-09-04 20:41:46 UTC (rev 733) +++ trunk/src/pfcglobalconfig.class.php 2006-09-05 16:24:23 UTC (rev 734) @@ -41,7 +41,7 @@ var $lockurl = "http://www.phpfreechat.net"; // this is the url where the users must be redirected when the chat is locked // these parameters are static (cached) - var $proxys = array("lock", "auth", "noflood", "censor", "log"); + var $proxys = array("lock", "auth", "checknickchange", "noflood", "censor", "log"); var $proxys_cfg = array("auth" => array(), "noflood" => array("limit"=>10,"delay"=>5), "censor" => array("words"=>array("fuck","sex","bitch"),"replaceby"=>"*"), @@ -398,11 +398,6 @@ // load debug url $this->debugurl = relativePath($this->client_script_path, dirname(__FILE__)."/../debug"); - - // check the frozen_nick parameter is used with a none empty nickname - if ($this->frozen_nick && $this->nick == "") - $this->errors[] = _pfc("frozen_nick can't be used with a empty nick"); - // check the language is known $lg_list = pfcI18N::GetAcceptedLanguage(); if ( $this->language != "" && !in_array($this->language, $lg_list) ) @@ -433,10 +428,6 @@ // load smileys from file $this->loadSmileyTheme(); - // do not froze nickname if it has not be specified - if ($this->nick == "" && $this->frozen_nick) - $this->frozen_nick = false; - // load version number from file $this->version = trim(file_get_contents(dirname(__FILE__)."/../version")); Modified: trunk/src/pfcuserconfig.class.php =================================================================== --- trunk/src/pfcuserconfig.class.php 2006-09-04 20:41:46 UTC (rev 733) +++ trunk/src/pfcuserconfig.class.php 2006-09-05 16:24:23 UTC (rev 734) @@ -30,7 +30,7 @@ // user parameters are cached in sessions $this->_getParam("nick"); - if (!isset($this->nick)) $this->_setParam("nick",$c->nick); + if (!isset($this->nick)) $this->_setParam("nick",""); // setup a blank nick if it is not yet in session $this->_getParam("active"); if (!isset($this->active)) $this->_setParam("active",false); $this->_getParam("channels"); @@ -57,8 +57,7 @@ function _setParam($p, $v) { $c =& pfcGlobalConfig::Instance(); - $nickid = "pfcuserconfig_".$c->getId(); - $nickid_param = $nickid."_".$p; + $nickid_param = "pfcuserconfig_".$c->getId()./*"_".$this->nickid.*/"_".$p; $_SESSION[$nickid_param] = $v; $this->$p = $v; } @@ -66,8 +65,7 @@ function _rmParam($p) { $c =& pfcGlobalConfig::Instance(); - $nickid = "pfcuserconfig_".$c->getId(); - $nickid_param = $nickid."_".$p; + $nickid_param = "pfcuserconfig_".$c->getId()./*"_".$this->nickid.*/"_".$p; unset($_SESSION[$nickid_param]); unset($this->$p); } Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-09-04 20:41:46 UTC (rev 733) +++ trunk/src/phpfreechat.class.php 2006-09-05 16:24:23 UTC (rev 734) @@ -247,9 +247,9 @@ foreach ($s_strs as $s_str) { $s_str = stripslashes($s_str); /* the :'( smileys needs this filter */ - $query .= preg_quote($s_str,'/')."|"; - $search[] = "/".preg_quote($s_str,'/')."/"; - $replace[] = '<img src="'.$s_file.'" alt="'.$s_str.'" title="'.$s_str.'" />'; + $query .= preg_quote($s_str,'/')."|"; + $search[] = "/".preg_quote($s_str,'/')."/"; + $replace[] = '<img src="'.$s_file.'" alt="'.$s_str.'" title="'.$s_str.'" />'; } } $query = substr($query, 0, strlen($query)-1); @@ -425,9 +425,9 @@ { // call the command if ($c->debug) - $cmd->run($xml_reponse, $cmdp); + $cmd->run($xml_reponse, $cmdp); else - @$cmd->run($xml_reponse, $cmdp); + @$cmd->run($xml_reponse, $cmdp); } else { @@ -447,8 +447,8 @@ // do not update twice // do not update when the user just quit if ($rawcmd != "update" && - $rawcmd != "quit" && - $u->nick != "") + $rawcmd != "quit" && + $u->nick != "") { // force an update just after a command is sent // thus the message user just poster is really fastly displayed @@ -460,9 +460,9 @@ $cmdp["recipient"] = $recipient; $cmdp["recipientid"] = $recipientid; if ($c->debug) - $cmd->run($xml_reponse, $cmdp); + $cmd->run($xml_reponse, $cmdp); else - @$cmd->run($xml_reponse, $cmdp); + @$cmd->run($xml_reponse, $cmdp); } if ($c->debug) Modified: trunk/src/proxys/auth.class.php =================================================================== --- trunk/src/proxys/auth.class.php 2006-09-04 20:41:46 UTC (rev 733) +++ trunk/src/proxys/auth.class.php 2006-09-05 16:24:23 UTC (rev 734) @@ -85,18 +85,6 @@ } } } - - // disallow to change nickname if frozen_nick is true - if ($this->name == "nick") - { - if ($param != $c->nick && - $c->frozen_nick == true) - { - $msg = _pfc("You are not allowed to change your nickname", $param); - $xml_reponse->addScript("pfc.handleResponse('".$this->proxyname."', 'nick', '".addslashes($msg)."');"); - return; - } - } // forward the command to the next proxy or to the final command $p["clientid"] = $clientid; Added: trunk/src/proxys/checknickchange.class.php =================================================================== --- trunk/src/proxys/checknickchange.class.php (rev 0) +++ trunk/src/proxys/checknickchange.class.php 2006-09-05 16:24:23 UTC (rev 734) @@ -0,0 +1,128 @@ +<?php +/** + * checknickchange.class.php + * + * Copyright © 2006 Stephane Gully <ste...@gm...> + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the + * Free Software Foundation, 51 Franklin St, Fifth Floor, + * Boston, MA 02110-1301 USA + */ +require_once dirname(__FILE__)."/../pfci18n.class.php"; +require_once dirname(__FILE__)."/../pfcuserconfig.class.php"; +require_once dirname(__FILE__)."/../pfcproxycommand.class.php"; + +/** + * pfcProxyCommand_checknickchange + * + * @author Stephane Gully <ste...@gm...> + */ +class pfcProxyCommand_checknickchange extends pfcProxyCommand +{ + function run(&$xml_reponse, $p) + { + $clientid = $p["clientid"]; + $param = $p["param"]; + $sender = $p["sender"]; + $recipient = $p["recipient"]; + $recipientid = $p["recipientid"]; + + $c =& $this->c; + $u =& $this->u; + + if ( $this->name == "nick") + { + $newnick = phpFreeChat::FilterNickname($param); + $oldnick = $u->nick; + + if ($newnick == $oldnick) + { + $xml_reponse->addScript("pfc.handleResponse('nick', 'notchanged', '".addslashes($newnick)."');"); + if ($c->debug) + pxlog("/nick ".$newnick." (user just reloded the page so let him keep his nickname without any warnings -> nickid=".$newnickid.")", "chat", $c->getId()); + return; + } + + // if the user want to change his nickname but the frozen_nick is enable + // then send him a warning + if ( $this->name == "nick" && + $u->nick != "" && + $param != $u->nick && + $c->frozen_nick == true && + $p["owner"] != "checknickchange" ) + { + $msg = _pfc("You are not allowed to change your nickname"); + $xml_reponse->addScript("pfc.handleResponse('".$this->proxyname."', 'nick', '".addslashes($msg)."');"); + return; + } + + $container =& $c->getContainerInstance(); + $newnickid = $container->getNickId($newnick); + $oldnickid = $container->getNickId($oldnick); + + // now check the nickname is not yet used (unsensitive case) + // 'BoB' and 'bob' must be considered same nicknames + $nick_in_use = false; + $online_users = $container->getOnlineNick(NULL); + if (isset($online_users["nickid"])) + foreach($online_users["nickid"] as $nid) + { + if (preg_match("/^".preg_quote($container->getNickname($nid))."$/i",$newnick)) + { + // the nick match + // just allow the owner to change his capitalised letters + if ($nid != $oldnickid) + $nick_in_use = true; + } + } + if ($nick_in_use) + { + $xml_reponse->addScript("pfc.handleResponse('nick', 'isused', '".addslashes($newnick)."');"); + if ($c->debug) + pxlog("/nick ".$newnick." (wanted nick is allready in use -> wantednickid=".$newnickid.")", "chat", $c->getId()); + return; + } + + if ( $newnickid != "undefined" ) + { + // @todo notify the user ? + return; + } + + } + + // allow nick changes only from the parameters array (server side) + if ($c->frozen_nick == true && + $u->nick != $c->nick && + $c->nick != "" && // don't change the nickname to empty or the asknick popup will loop indefinatly + $p["owner"] != "checknickchange") + { + // change the user nickname + $cmdp = $p; + $cmdp["param"] = $c->nick; + $cmdp["owner"] = "checknickchange"; + $cmd =& pfcCommand::Factory("nick"); + $cmd->run($xml_reponse, $cmdp); + return; + } + + + + + // forward the command to the next proxy or to the final command + $this->next->run($xml_reponse, $p); + } +} + +?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-04 20:41:59
|
Revision: 733 http://svn.sourceforge.net/phpfreechat/?rev=733&view=rev Author: kerphi Date: 2006-09-04 13:41:46 -0700 (Mon, 04 Sep 2006) Log Message: ----------- more explicite message Modified Paths: -------------- trunk/src/phpfreechat.class.php Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-09-04 19:46:27 UTC (rev 732) +++ trunk/src/phpfreechat.class.php 2006-09-04 20:41:46 UTC (rev 733) @@ -184,7 +184,7 @@ // or keep a backling to http://www.phpfreechat on your partner page // it helps phpfreechat promotion over the Web. // (remember it's a free program) - $output .= "<p>"._pfc("Error: the chat cannot be loaded, check the public directory rights or ask some help on the forum")." <a href=\"http://www.phpfreechat.net/forum/\">www.phpfreechat.net/forum</a></p>"; + $output .= "<p>"._pfc("Error: the chat cannot be loaded! two possibilities: your browser doesn't support javascript or you didn't setup correctly the server directories rights - don't hesitate to ask some help on the forum")." <a href=\"http://www.phpfreechat.net/forum/\">www.phpfreechat.net/forum</a></p>"; $output .= "<a href=\"http://www.phpfreechat.net\"><img src=\"http://www.phpfreechat.net/pub/logo_80x15.gif\" alt=\"PHP FREE CHAT [powered by phpFreeChat-".$c->version."]\" title=\"PHP FREE CHAT [powered by phpFreeChat-".$c->version."]\" /></a>"; $output .= "</div>"; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-04 19:46:37
|
Revision: 732 http://svn.sourceforge.net/phpfreechat/?rev=732&view=rev Author: kerphi Date: 2006-09-04 12:46:27 -0700 (Mon, 04 Sep 2006) Log Message: ----------- Check all parameters types at init step Modified Paths: -------------- trunk/src/pfcglobalconfig.class.php Modified: trunk/src/pfcglobalconfig.class.php =================================================================== --- trunk/src/pfcglobalconfig.class.php 2006-09-03 17:28:36 UTC (rev 731) +++ trunk/src/pfcglobalconfig.class.php 2006-09-04 19:46:27 UTC (rev 732) @@ -101,10 +101,16 @@ var $debugurl = ""; var $debug = false; var $debugxajax = false; - var $dyn_params = array("nick","isadmin","islocked","admins"); + + // private parameters + var $_dyn_params = array("nick","isadmin","islocked","admins"); + var $_params_type = array(); function pfcGlobalConfig( $params = array() ) { + // first of all, save our current state in order to be able to check for variable types later + $this->_saveParamsTypes(); + // setup the local for translated messages pfcI18N::Init(isset($params["language"]) ? $params["language"] : ""); @@ -163,7 +169,7 @@ } // load dynamic parameter even if the config exists in the cache - foreach ( $this->dyn_params as $dp ) + foreach ( $this->_dyn_params as $dp ) if (isset($params[$dp])) $this->$dp = $params[$dp]; @@ -203,6 +209,22 @@ } /** + * This function saves all the parameters types in order to check later if the types are ok + */ + function _saveParamsTypes() + { + $vars = get_object_vars($this); + foreach($vars as $k => $v) + { + if (is_string($v)) $this->_params_type["string"][] = $k; + else if (is_bool($v)) $this->_params_type["bool"][] = $k; + else if (is_array($v)) $this->_params_type["array"][] = $k; + else if (is_int($v) && $v>=0) $this->_params_type["positivenumeric"][] = $k; + else $this->_params_type["misc"][] = $k; + } + } + + /** * Initialize the phpfreechat configuration * this initialisation is done once at startup then it is stored into a session cache */ @@ -211,6 +233,32 @@ $ok = true; if ($this->debug) pxlog("pfcGlobalConfig::init()", "chatconfig", $this->getId()); + + // check the parameters types + $array_params = $this->_params_type["array"]; + foreach( $array_params as $ap ) + { + if (!is_array($this->$ap)) + $this->errors[] = _pfc("'%s' parameter must be an array", $ap); + } + $numerical_positive_params = $this->_params_type["positivenumeric"]; + foreach( $numerical_positive_params as $npp ) + { + if (!is_int($this->$npp) || $this->$npp < 0) + $this->errors[] = _pfc("'%s' parameter must be a positive number", $npp); + } + $boolean_params = $this->_params_type["bool"]; + foreach( $boolean_params as $bp ) + { + if (!is_bool($this->$bp)) + $this->errors[] = _pfc("'%s' parameter must be a boolean", $bp); + } + $string_params = $this->_params_type["string"]; + foreach( $string_params as $sp ) + { + if (!is_string($this->$sp)) + $this->errors[] = _pfc("'%s' parameter must be a charatere string", $sp); + } if ($this->title == "") $this->title = _pfc("My Chat"); if ($this->xajaxpath == "") $this->xajaxpath = dirname(__FILE__)."/../lib/xajax_0.2.3"; @@ -354,37 +402,7 @@ // check the frozen_nick parameter is used with a none empty nickname if ($this->frozen_nick && $this->nick == "") $this->errors[] = _pfc("frozen_nick can't be used with a empty nick"); - - // check if channels parameter is a strings array - if (!is_array($this->channels)) - $this->errors[] = _pfc("'%s' parameter must be an array", "channels"); - else - foreach($this->channels as $chan) - { - if (!is_string($chan)) - $this->errors[] = _pfc("'%s' value must be a string", serialize($chan)); - } - - // check the max_msg is >= 0 - if (!is_numeric($this->max_msg) || $this->max_msg < 0) - $this->errors[] = _pfc("'%s' parameter must be a positive number", "max_msg"); - - // check the max_nick_len is >= 0 - if (!is_numeric($this->max_nick_len) || $this->max_nick_len < 0) - $this->errors[] = _pfc("'%s' parameter must be a positive number", "max_nick_len"); - // check the max_text_len is >= 0 - if (!is_numeric($this->max_text_len) || $this->max_text_len < 0) - $this->errors[] = _pfc("'%s' parameter must be a positive number", "max_text_len"); - - // check the refresh_delay is >= 0 - if (!is_numeric($this->refresh_delay) || $this->refresh_delay < 0) - $this->errors[] = _pfc("'%s' parameter must be a positive number", "refresh_delay"); - - // check the timeout is >= 0 - if (!is_numeric($this->timeout) || $this->timeout < 0) - $this->errors[] = _pfc("'%s' parameter must be a positive number", "timeout"); - // check the language is known $lg_list = pfcI18N::GetAcceptedLanguage(); if ( $this->language != "" && !in_array($this->language, $lg_list) ) @@ -507,7 +525,7 @@ foreach($pfc_configvar as $key => $val) { // the dynamics parameters must not be cached - if (!in_array($key,$this->dyn_params)) + if (!in_array($key,$this->_dyn_params)) $this->$key = $val; } @@ -533,7 +551,7 @@ if (count($errors) > 0) { @unlink($cachefile_lock); // destroy the lock file for the next attempt - echo "<ul>"; foreach( $errors as $e ) echo "<li>".$e."</li>"; echo "</ul>"; + echo "<p>"._pfc("Please correct these errors").":</p><ul>"; foreach( $errors as $e ) echo "<li>".$e."</li>"; echo "</ul>"; exit; } // save the validated config in cache @@ -589,4 +607,4 @@ } } -?> +?> \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-03 17:28:42
|
Revision: 731 http://svn.sourceforge.net/phpfreechat/?rev=731&view=rev Author: kerphi Date: 2006-09-03 10:28:36 -0700 (Sun, 03 Sep 2006) Log Message: ----------- Bug fix: on mozilla if the user cancel the bbcode prompt popup, a js error occurs Modified Paths: -------------- trunk/src/client/pfcclient.js Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-09-03 16:22:24 UTC (rev 730) +++ trunk/src/client/pfcclient.js 2006-09-03 17:28:36 UTC (rev 731) @@ -1206,6 +1206,7 @@ if (startPos == endPos && promptifselempty) { text = prompt(this.res.getLabel('Enter the text to format'),''); + if (text == null) text = ""; extralength = text.length; } if (text.length > 0 || !promptifselempty) @@ -1220,6 +1221,7 @@ else { var text = prompt(this.res.getLabel('Enter the text to format'),''); + if (text == null) text = ""; if (text.length > 0 || !promptifselempty) { msgfield.value += open + text + close; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-03 16:22:40
|
Revision: 730 http://svn.sourceforge.net/phpfreechat/?rev=730&view=rev Author: kerphi Date: 2006-09-03 09:22:24 -0700 (Sun, 03 Sep 2006) Log Message: ----------- Bug fix: the xajax server url script was not correctly calculated Modified Paths: -------------- trunk/src/phpfreechat.class.php Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-09-03 13:34:14 UTC (rev 729) +++ trunk/src/phpfreechat.class.php 2006-09-03 16:22:24 UTC (rev 730) @@ -63,7 +63,7 @@ if (!class_exists("xajax")) if (file_exists($c->xajaxpath."/xajax.inc.php")) { - require_once $c->xajaxpath."/xajax.inc.php"; + require_once $c->xajaxpath."/xajax.inc.php"; $this->xajax = new xajax($c->server_script_url.(isset($_SERVER["QUERY_STRING"]) && $_SERVER["QUERY_STRING"] != "" ? "?".$_SERVER["QUERY_STRING"] : ""), $c->prefix); if ($c->debugxajax) $this->xajax->debugOn(); $this->xajax->waitCursorOff(); // do not show a wait cursor during chat updates @@ -88,7 +88,7 @@ $u =& pfcUserConfig::Instance(); $output .= '<script type="text/javascript"> -var xajaxRequestUri="'.$c->server_script_url.'"; +var xajaxRequestUri="'.$c->server_script_url.(isset($_SERVER["QUERY_STRING"]) && $_SERVER["QUERY_STRING"] != "" ? "?".$_SERVER["QUERY_STRING"] : "").'"; var xajaxDebug=false; var xajaxStatusMessages=false; var xajaxWaitCursor=false; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-03 13:36:36
|
Revision: 729 http://svn.sourceforge.net/phpfreechat/?rev=729&view=rev Author: kerphi Date: 2006-09-03 06:34:14 -0700 (Sun, 03 Sep 2006) Log Message: ----------- do not add the index.php file into checkmd5 Modified Paths: -------------- trunk/misc/checkmd5 Modified: trunk/misc/checkmd5 =================================================================== --- trunk/misc/checkmd5 2006-09-03 09:18:13 UTC (rev 728) +++ trunk/misc/checkmd5 2006-09-03 13:34:14 UTC (rev 729) @@ -31,11 +31,14 @@ echo '$files_ko = array();' >> $TMP for f in `find . -type f` do - sum=`md5sum $f | sed "s/\s.*$//g"` - echo 'if (md5(file_get_contents("'$f'")) == "'$sum'")' >> $TMP - echo ' $files_ok[] = "<span style=\"color:#3A3\">ok - '$f'</span>\n";' >> $TMP - echo 'else' >> $TMP - echo ' $files_ko[] = "<span style=\"color:#F33\">corrupted - '$f' (please replace this file by a correct one)</span>\n";' >> $TMP + if ( test $f != "./index.php" ) + then + sum=`md5sum $f | sed "s/\s.*$//g"` + echo 'if (md5(file_get_contents("'$f'")) == "'$sum'")' >> $TMP + echo ' $files_ok[] = "<span style=\"color:#3A3\">ok - '$f'</span>\n";' >> $TMP + echo 'else' >> $TMP + echo ' $files_ko[] = "<span style=\"color:#F33\">corrupted - '$f' (please replace this file by a correct one)</span>\n";' >> $TMP + fi done echo 'echo "<h2>Checking phpfreechat files validity</h2>";' >> $TMP This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-03 09:18:17
|
Revision: 728 http://svn.sourceforge.net/phpfreechat/?rev=728&view=rev Author: kerphi Date: 2006-09-03 02:18:13 -0700 (Sun, 03 Sep 2006) Log Message: ----------- remove doubled parameter Modified Paths: -------------- trunk/src/client/chat.js.tpl.php Modified: trunk/src/client/chat.js.tpl.php =================================================================== --- trunk/src/client/chat.js.tpl.php 2006-09-03 09:02:19 UTC (rev 727) +++ trunk/src/client/chat.js.tpl.php 2006-09-03 09:18:13 UTC (rev 728) @@ -12,7 +12,6 @@ var pfc_max_text_len = <?php echo $max_text_len; ?>; var pfc_quit_on_closedwindow = <?php echo $quit_on_closedwindow ? "true" : "false"; ?>; var pfc_debug = <?php echo $debug ? "true" : "false"; ?>; -var pfc_max_text_len = <?php echo $max_text_len; ?>; var pfc_btn_sh_smileys = <?php echo $btn_sh_smileys ? "true" : "false"; ?>; var pfc_btn_sh_whosonline = <?php echo $btn_sh_whosonline ? "true" : "false"; ?>; var pfc_connect_at_startup = <?php echo $connect_at_startup ? "true" : "false"; ?>; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-03 09:02:31
|
Revision: 727 http://svn.sourceforge.net/phpfreechat/?rev=727&view=rev Author: kerphi Date: 2006-09-03 02:02:19 -0700 (Sun, 03 Sep 2006) Log Message: ----------- [en] Replace utf8_substr code by a less system dependant one coming from typo3 code. [fr]Remplacement de la fonction utf8_substr par du code venant de typo3 moins d?\195?\169pendant du syst?\195?\168me, en particulier l'ancien code d?\195?\169pendait de preg_match_all qui devait ?\195?\170tre compil?\195?\169 avec le support utf8. Modified Paths: -------------- trunk/src/phpfreechat.class.php Added Paths: ----------- trunk/lib/utf8/utf8_char2byte_pos.php trunk/lib/utf8/utf8_substr.php Removed Paths: ------------- trunk/lib/utf8/utf8.php Deleted: trunk/lib/utf8/utf8.php =================================================================== --- trunk/lib/utf8/utf8.php 2006-09-02 21:20:15 UTC (rev 726) +++ trunk/lib/utf8/utf8.php 2006-09-03 09:02:19 UTC (rev 727) @@ -1,820 +0,0 @@ -<?php -/** - * UTF8 helper functions - * - * @license LGPL (http://www.gnu.org/copyleft/lesser.html) - * @author Andreas Gohr <an...@sp...> - */ - -/** - * URL-Encode a filename to allow unicodecharacters - * - * Slashes are not encoded - * - * When the second parameter is true the string will - * be encoded only if non ASCII characters are detected - - * This makes it safe to run it multiple times on the - * same string (default is true) - * - * @author Andreas Gohr <an...@sp...> - * @see urlencode - */ -function utf8_encodeFN($file,$safe=true){ - if($safe && preg_match('#^[a-zA-Z0-9/_\-.%]+$#',$file)){ - return $file; - } - $file = urlencode($file); - $file = str_replace('%2F','/',$file); - return $file; -} - -/** - * URL-Decode a filename - * - * This is just a wrapper around urldecode - * - * @author Andreas Gohr <an...@sp...> - * @see urldecode - */ -function utf8_decodeFN($file){ - $file = urldecode($file); - return $file; -} - -/** - * Checks if a string contains 7bit ASCII only - * - * @author Andreas Gohr <an...@sp...> - */ -function utf8_isASCII($str){ - for($i=0; $i<strlen($str); $i++){ - if(ord($str{$i}) >127) return false; - } - return true; -} - -/** - * Strips all highbyte chars - * - * Returns a pure ASCII7 string - * - * @author Andreas Gohr <an...@sp...> - */ -function utf8_strip($str){ - $ascii = ''; - for($i=0; $i<strlen($str); $i++){ - if(ord($str{$i}) <128){ - $ascii .= $str{$i}; - } - } - return $ascii; -} - -/** - * Tries to detect if a string is in Unicode encoding - * - * @author <bm...@ss...> - * @link http://www.php.net/manual/en/function.utf8-encode.php - */ -function utf8_check($Str) { - for ($i=0; $i<strlen($Str); $i++) { - if (ord($Str[$i]) < 0x80) continue; # 0bbbbbbb - elseif ((ord($Str[$i]) & 0xE0) == 0xC0) $n=1; # 110bbbbb - elseif ((ord($Str[$i]) & 0xF0) == 0xE0) $n=2; # 1110bbbb - elseif ((ord($Str[$i]) & 0xF8) == 0xF0) $n=3; # 11110bbb - elseif ((ord($Str[$i]) & 0xFC) == 0xF8) $n=4; # 111110bb - elseif ((ord($Str[$i]) & 0xFE) == 0xFC) $n=5; # 1111110b - else return false; # Does not match any model - for ($j=0; $j<$n; $j++) { # n bytes matching 10bbbbbb follow ? - if ((++$i == strlen($Str)) || ((ord($Str[$i]) & 0xC0) != 0x80)) - return false; - } - } - return true; -} - -/** - * Unicode aware replacement for strlen() - * - * utf8_decode() converts characters that are not in ISO-8859-1 - * to '?', which, for the purpose of counting, is alright - It's - * even faster than mb_strlen. - * - * @author <chernyshevsky at hotmail dot com> - * @see strlen() - * @see utf8_decode() - */ -function utf8_strlen($string){ - return strlen(utf8_decode($string)); -} - -/** - * Unicode aware replacement for substr() - * - * @author lmak at NOSPAM dot iti dot gr - * @link http://www.php.net/manual/en/function.substr.php - * @see substr() - */ -function utf8_substr($str,$start,$length=null){ - preg_match_all("/./u", $str, $ar); - - if($length != null) { - return join("",array_slice($ar[0],$start,$length)); - } else { - return join("",array_slice($ar[0],$start)); - } -} - -/** - * Unicode aware replacement for substr_replace() - * - * @author Andreas Gohr <an...@sp...> - * @see substr_replace() - */ -function utf8_substr_replace($string, $replacement, $start , $length=0 ){ - $ret = ''; - if($start>0) $ret .= utf8_substr($string, 0, $start); - $ret .= $replacement; - $ret .= utf8_substr($string, $start+$length); - return $ret; -} - -/** - * Unicode aware replacement for explode - * - * @TODO support third limit arg - * @author Harry Fuecks <hf...@gm...> - * @see explode(); - */ -function utf8_explode($sep, $str) { - if ( $sep == '' ) { - trigger_error('Empty delimiter',E_USER_WARNING); - return FALSE; - } - - return preg_split('!'.preg_quote($sep,'!').'!u',$str); -} - -/** - * Unicode aware replacement for strrepalce() - * - * @todo support PHP5 count (fourth arg) - * @author Harry Fuecks <hf...@gm...> - * @see strreplace(); - */ -function utf8_str_replace($s,$r,$str){ - if(!is_array($s)){ - $s = '!'.preg_quote($s,'!').'!u'; - }else{ - foreach ($s as $k => $v) { - $s[$k] = '!'.preg_quote($v).'!u'; - } - } - return preg_replace($s,$r,$str); -} - -/** - * Unicode aware replacement for ltrim() - * - * @author Andreas Gohr <an...@sp...> - * @see ltrim() - * @return string - */ -function utf8_ltrim($str,$charlist=''){ - if($charlist == '') return ltrim($str); - - //quote charlist for use in a characterclass - $charlist = preg_replace('!([\\\\\\-\\]\\[/])!','\\\${1}',$charlist); - - return preg_replace('/^['.$charlist.']+/u','',$str); -} - -/** - * Unicode aware replacement for rtrim() - * - * @author Andreas Gohr <an...@sp...> - * @see rtrim() - * @return string - */ -function utf8_rtrim($str,$charlist=''){ - if($charlist == '') return rtrim($str); - - //quote charlist for use in a characterclass - $charlist = preg_replace('!([\\\\\\-\\]\\[/])!','\\\${1}',$charlist); - - return preg_replace('/['.$charlist.']+$/u','',$str); -} - -/** - * Unicode aware replacement for trim() - * - * @author Andreas Gohr <an...@sp...> - * @see trim() - * @return string - */ -function utf8_trim($str,$charlist='') { - if($charlist == '') return trim($str); - - return utf8_ltrim(utf8_rtrim($str)); -} - - -/** - * This is a unicode aware replacement for strtolower() - * - * Uses mb_string extension if available - * - * @author Andreas Gohr <an...@sp...> - * @see strtolower() - * @see utf8_strtoupper() - */ -function utf8_strtolower($string){ - if(!defined('UTF8_NOMBSTRING') && function_exists('mb_strtolower')) - return mb_strtolower($string,'utf-8'); - - global $UTF8_UPPER_TO_LOWER; - $uni = utf8_to_unicode($string); - $cnt = count($uni); - for ($i=0; $i < $cnt; $i++){ - if($UTF8_UPPER_TO_LOWER[$uni[$i]]){ - $uni[$i] = $UTF8_UPPER_TO_LOWER[$uni[$i]]; - } - } - return unicode_to_utf8($uni); -} - -/** - * This is a unicode aware replacement for strtoupper() - * - * Uses mb_string extension if available - * - * @author Andreas Gohr <an...@sp...> - * @see strtoupper() - * @see utf8_strtoupper() - */ -function utf8_strtoupper($string){ - if(!defined('UTF8_NOMBSTRING') && function_exists('mb_strtolower')) - return mb_strtoupper($string,'utf-8'); - - global $UTF8_LOWER_TO_UPPER; - $uni = utf8_to_unicode($string); - $cnt = count($uni); - for ($i=0; $i < $cnt; $i++){ - if($UTF8_LOWER_TO_UPPER[$uni[$i]]){ - $uni[$i] = $UTF8_LOWER_TO_UPPER[$uni[$i]]; - } - } - return unicode_to_utf8($uni); -} - -/** - * Replace accented UTF-8 characters by unaccented ASCII-7 equivalents - * - * Use the optional parameter to just deaccent lower ($case = -1) or upper ($case = 1) - * letters. Default is to deaccent both cases ($case = 0) - * - * @author Andreas Gohr <an...@sp...> - */ -function utf8_deaccent($string,$case=0){ - if($case <= 0){ - global $UTF8_LOWER_ACCENTS; - $string = str_replace(array_keys($UTF8_LOWER_ACCENTS),array_values($UTF8_LOWER_ACCENTS),$string); - } - if($case >= 0){ - global $UTF8_UPPER_ACCENTS; - $string = str_replace(array_keys($UTF8_UPPER_ACCENTS),array_values($UTF8_UPPER_ACCENTS),$string); - } - return $string; -} - -/** - * Romanize a non-latin string - * - * @author Andreas Gohr <an...@sp...> - */ -function utf8_romanize($string){ - if(utf8_isASCII($string)) return $string; //nothing to do - - global $UTF8_ROMANIZATION; - return strtr($string,$UTF8_ROMANIZATION); -} - -/** - * Removes special characters (nonalphanumeric) from a UTF-8 string - * - * This function adds the controlchars 0x00 to 0x19 to the array of - * stripped chars (they are not included in $UTF8_SPECIAL_CHARS) - * - * @author Andreas Gohr <an...@sp...> - * @param string $string The UTF8 string to strip of special chars - * @param string $repl Replace special with this string - * @param string $additional Additional chars to strip (used in regexp char class) - */ -function utf8_stripspecials($string,$repl='',$additional=''){ - global $UTF8_SPECIAL_CHARS; - - static $specials = null; - if(is_null($specials)){ - $specials = preg_quote(unicode_to_utf8($UTF8_SPECIAL_CHARS), '/'); - } - - return preg_replace('/['.$additional.'\x00-\x19'.$specials.']/u',$repl,$string); -} - -/** - * This is an Unicode aware replacement for strpos - * - * Uses mb_string extension if available - * - * @author Harry Fuecks <hf...@gm...> - * @see strpos() - */ -function utf8_strpos($haystack, $needle,$offset=0) { - if(!defined('UTF8_NOMBSTRING') && function_exists('mb_strpos')) - return mb_strpos($haystack,$needle,$offset,'utf-8'); - - if(!$offset){ - $ar = utf8_explode($needle, $str); - if ( count($ar) > 1 ) { - return utf8_strlen($ar[0]); - } - return false; - }else{ - if ( !is_int($offset) ) { - trigger_error('Offset must be an integer',E_USER_WARNING); - return false; - } - - $str = utf8_substr($str, $offset); - - if ( false !== ($pos = utf8_strpos($str,$needle))){ - return $pos + $offset; - } - return false; - } -} - -/** - * Encodes UTF-8 characters to HTML entities - * - * @author <vpribish at shopping dot com> - * @link http://www.php.net/manual/en/function.utf8-decode.php - */ -function utf8_tohtml ($str) { - $ret = ''; - $max = strlen($str); - $last = 0; // keeps the index of the last regular character - for ($i=0; $i<$max; $i++) { - $c = $str{$i}; - $c1 = ord($c); - if ($c1>>5 == 6) { // 110x xxxx, 110 prefix for 2 bytes unicode - $ret .= substr($str, $last, $i-$last); // append all the regular characters we've passed - $c1 &= 31; // remove the 3 bit two bytes prefix - $c2 = ord($str{++$i}); // the next byte - $c2 &= 63; // remove the 2 bit trailing byte prefix - $c2 |= (($c1 & 3) << 6); // last 2 bits of c1 become first 2 of c2 - $c1 >>= 2; // c1 shifts 2 to the right - $ret .= '&#' . ($c1 * 100 + $c2) . ';'; // this is the fastest string concatenation - $last = $i+1; - } - } - return $ret . substr($str, $last, $i); // append the last batch of regular characters -} - -/** - * This function returns any UTF-8 encoded text as a list of - * Unicode values: - * - * @author Scott Michael Reynen <sc...@ra...> - * @link http://www.randomchaos.com/document.php?source=php_and_unicode - * @see unicode_to_utf8() - */ -function utf8_to_unicode( &$str ) { - $unicode = array(); - $values = array(); - $lookingFor = 1; - - for ($i = 0; $i < strlen( $str ); $i++ ) { - $thisValue = ord( $str[ $i ] ); - if ( $thisValue < 128 ) $unicode[] = $thisValue; - else { - if ( count( $values ) == 0 ) $lookingFor = ( $thisValue < 224 ) ? 2 : 3; - $values[] = $thisValue; - if ( count( $values ) == $lookingFor ) { - $number = ( $lookingFor == 3 ) ? - ( ( $values[0] % 16 ) * 4096 ) + ( ( $values[1] % 64 ) * 64 ) + ( $values[2] % 64 ): - ( ( $values[0] % 32 ) * 64 ) + ( $values[1] % 64 ); - $unicode[] = $number; - $values = array(); - $lookingFor = 1; - } - } - } - return $unicode; -} - -/** - * This function converts a Unicode array back to its UTF-8 representation - * - * @author Scott Michael Reynen <sc...@ra...> - * @link http://www.randomchaos.com/document.php?source=php_and_unicode - * @see utf8_to_unicode() - */ -function unicode_to_utf8( &$str ) { - if (!is_array($str)) return ''; - - $utf8 = ''; - foreach( $str as $unicode ) { - if ( $unicode < 128 ) { - $utf8.= chr( $unicode ); - } elseif ( $unicode < 2048 ) { - $utf8.= chr( 192 + ( ( $unicode - ( $unicode % 64 ) ) / 64 ) ); - $utf8.= chr( 128 + ( $unicode % 64 ) ); - } else { - $utf8.= chr( 224 + ( ( $unicode - ( $unicode % 4096 ) ) / 4096 ) ); - $utf8.= chr( 128 + ( ( ( $unicode % 4096 ) - ( $unicode % 64 ) ) / 64 ) ); - $utf8.= chr( 128 + ( $unicode % 64 ) ); - } - } - return $utf8; -} - -/** - * UTF-8 to UTF-16BE conversion. - * - * Maybe really UCS-2 without mb_string due to utf8_to_unicode limits - */ -function utf8_to_utf16be(&$str, $bom = false) { - $out = $bom ? "\xFE\xFF" : ''; - if(!defined('UTF8_NOMBSTRING') && function_exists('mb_convert_encoding')) - return $out.mb_convert_encoding($str,'UTF-16BE','UTF-8'); - - $uni = utf8_to_unicode($str); - foreach($uni as $cp){ - $out .= pack('n',$cp); - } - return $out; -} - -/** - * UTF-8 to UTF-16BE conversion. - * - * Maybe really UCS-2 without mb_string due to utf8_to_unicode limits - */ -function utf16be_to_utf8(&$str) { - $uni = unpack('n*',$str); - return unicode_to_utf8($uni); -} - -/** - * UTF-8 Case lookup table - * - * This lookuptable defines the upper case letters to their correspponding - * lower case letter in UTF-8 - * - * @author Andreas Gohr <an...@sp...> - */ -static $UTF8_LOWER_TO_UPPER = array( - 0x0061=>0x0041, 0x03C6=>0x03A6, 0x0163=>0x0162, 0x00E5=>0x00C5, 0x0062=>0x0042, - 0x013A=>0x0139, 0x00E1=>0x00C1, 0x0142=>0x0141, 0x03CD=>0x038E, 0x0101=>0x0100, - 0x0491=>0x0490, 0x03B4=>0x0394, 0x015B=>0x015A, 0x0064=>0x0044, 0x03B3=>0x0393, - 0x00F4=>0x00D4, 0x044A=>0x042A, 0x0439=>0x0419, 0x0113=>0x0112, 0x043C=>0x041C, - 0x015F=>0x015E, 0x0144=>0x0143, 0x00EE=>0x00CE, 0x045E=>0x040E, 0x044F=>0x042F, - 0x03BA=>0x039A, 0x0155=>0x0154, 0x0069=>0x0049, 0x0073=>0x0053, 0x1E1F=>0x1E1E, - 0x0135=>0x0134, 0x0447=>0x0427, 0x03C0=>0x03A0, 0x0438=>0x0418, 0x00F3=>0x00D3, - 0x0440=>0x0420, 0x0454=>0x0404, 0x0435=>0x0415, 0x0449=>0x0429, 0x014B=>0x014A, - 0x0431=>0x0411, 0x0459=>0x0409, 0x1E03=>0x1E02, 0x00F6=>0x00D6, 0x00F9=>0x00D9, - 0x006E=>0x004E, 0x0451=>0x0401, 0x03C4=>0x03A4, 0x0443=>0x0423, 0x015D=>0x015C, - 0x0453=>0x0403, 0x03C8=>0x03A8, 0x0159=>0x0158, 0x0067=>0x0047, 0x00E4=>0x00C4, - 0x03AC=>0x0386, 0x03AE=>0x0389, 0x0167=>0x0166, 0x03BE=>0x039E, 0x0165=>0x0164, - 0x0117=>0x0116, 0x0109=>0x0108, 0x0076=>0x0056, 0x00FE=>0x00DE, 0x0157=>0x0156, - 0x00FA=>0x00DA, 0x1E61=>0x1E60, 0x1E83=>0x1E82, 0x00E2=>0x00C2, 0x0119=>0x0118, - 0x0146=>0x0145, 0x0070=>0x0050, 0x0151=>0x0150, 0x044E=>0x042E, 0x0129=>0x0128, - 0x03C7=>0x03A7, 0x013E=>0x013D, 0x0442=>0x0422, 0x007A=>0x005A, 0x0448=>0x0428, - 0x03C1=>0x03A1, 0x1E81=>0x1E80, 0x016D=>0x016C, 0x00F5=>0x00D5, 0x0075=>0x0055, - 0x0177=>0x0176, 0x00FC=>0x00DC, 0x1E57=>0x1E56, 0x03C3=>0x03A3, 0x043A=>0x041A, - 0x006D=>0x004D, 0x016B=>0x016A, 0x0171=>0x0170, 0x0444=>0x0424, 0x00EC=>0x00CC, - 0x0169=>0x0168, 0x03BF=>0x039F, 0x006B=>0x004B, 0x00F2=>0x00D2, 0x00E0=>0x00C0, - 0x0434=>0x0414, 0x03C9=>0x03A9, 0x1E6B=>0x1E6A, 0x00E3=>0x00C3, 0x044D=>0x042D, - 0x0436=>0x0416, 0x01A1=>0x01A0, 0x010D=>0x010C, 0x011D=>0x011C, 0x00F0=>0x00D0, - 0x013C=>0x013B, 0x045F=>0x040F, 0x045A=>0x040A, 0x00E8=>0x00C8, 0x03C5=>0x03A5, - 0x0066=>0x0046, 0x00FD=>0x00DD, 0x0063=>0x0043, 0x021B=>0x021A, 0x00EA=>0x00CA, - 0x03B9=>0x0399, 0x017A=>0x0179, 0x00EF=>0x00CF, 0x01B0=>0x01AF, 0x0065=>0x0045, - 0x03BB=>0x039B, 0x03B8=>0x0398, 0x03BC=>0x039C, 0x045C=>0x040C, 0x043F=>0x041F, - 0x044C=>0x042C, 0x00FE=>0x00DE, 0x00F0=>0x00D0, 0x1EF3=>0x1EF2, 0x0068=>0x0048, - 0x00EB=>0x00CB, 0x0111=>0x0110, 0x0433=>0x0413, 0x012F=>0x012E, 0x00E6=>0x00C6, - 0x0078=>0x0058, 0x0161=>0x0160, 0x016F=>0x016E, 0x03B1=>0x0391, 0x0457=>0x0407, - 0x0173=>0x0172, 0x00FF=>0x0178, 0x006F=>0x004F, 0x043B=>0x041B, 0x03B5=>0x0395, - 0x0445=>0x0425, 0x0121=>0x0120, 0x017E=>0x017D, 0x017C=>0x017B, 0x03B6=>0x0396, - 0x03B2=>0x0392, 0x03AD=>0x0388, 0x1E85=>0x1E84, 0x0175=>0x0174, 0x0071=>0x0051, - 0x0437=>0x0417, 0x1E0B=>0x1E0A, 0x0148=>0x0147, 0x0105=>0x0104, 0x0458=>0x0408, - 0x014D=>0x014C, 0x00ED=>0x00CD, 0x0079=>0x0059, 0x010B=>0x010A, 0x03CE=>0x038F, - 0x0072=>0x0052, 0x0430=>0x0410, 0x0455=>0x0405, 0x0452=>0x0402, 0x0127=>0x0126, - 0x0137=>0x0136, 0x012B=>0x012A, 0x03AF=>0x038A, 0x044B=>0x042B, 0x006C=>0x004C, - 0x03B7=>0x0397, 0x0125=>0x0124, 0x0219=>0x0218, 0x00FB=>0x00DB, 0x011F=>0x011E, - 0x043E=>0x041E, 0x1E41=>0x1E40, 0x03BD=>0x039D, 0x0107=>0x0106, 0x03CB=>0x03AB, - 0x0446=>0x0426, 0x00FE=>0x00DE, 0x00E7=>0x00C7, 0x03CA=>0x03AA, 0x0441=>0x0421, - 0x0432=>0x0412, 0x010F=>0x010E, 0x00F8=>0x00D8, 0x0077=>0x0057, 0x011B=>0x011A, - 0x0074=>0x0054, 0x006A=>0x004A, 0x045B=>0x040B, 0x0456=>0x0406, 0x0103=>0x0102, - 0x03BB=>0x039B, 0x00F1=>0x00D1, 0x043D=>0x041D, 0x03CC=>0x038C, 0x00E9=>0x00C9, - 0x00F0=>0x00D0, 0x0457=>0x0407, 0x0123=>0x0122, -); - -/** - * UTF-8 Case lookup table - * - * This lookuptable defines the lower case letters to their correspponding - * upper case letter in UTF-8 (it does so by flipping $UTF8_LOWER_TO_UPPER) - * - * @author Andreas Gohr <an...@sp...> - */ -$UTF8_UPPER_TO_LOWER = @array_flip($UTF8_LOWER_TO_UPPER); - -/** - * UTF-8 lookup table for lower case accented letters - * - * This lookuptable defines replacements for accented characters from the ASCII-7 - * range. This are lower case letters only. - * - * @author Andreas Gohr <an...@sp...> - * @see utf8_deaccent() - */ -$UTF8_LOWER_ACCENTS = array( - 'à' => 'a', 'ô' => 'o', 'ď' => 'd', 'ḟ' => 'f', 'ë' => 'e', 'š' => 's', 'ơ' => 'o', - 'ß' => 'ss', 'ă' => 'a', 'ř' => 'r', 'ț' => 't', 'ň' => 'n', 'ā' => 'a', 'ķ' => 'k', - 'ŝ' => 's', 'ỳ' => 'y', 'ņ' => 'n', 'ĺ' => 'l', 'ħ' => 'h', 'ṗ' => 'p', 'ó' => 'o', - 'ú' => 'u', 'ě' => 'e', 'é' => 'e', 'ç' => 'c', 'ẁ' => 'w', 'ċ' => 'c', 'õ' => 'o', - 'ṡ' => 's', 'ø' => 'o', 'ģ' => 'g', 'ŧ' => 't', 'ș' => 's', 'ė' => 'e', 'ĉ' => 'c', - 'ś' => 's', 'î' => 'i', 'ű' => 'u', 'ć' => 'c', 'ę' => 'e', 'ŵ' => 'w', 'ṫ' => 't', - 'ū' => 'u', 'č' => 'c', 'ö' => 'oe', 'è' => 'e', 'ŷ' => 'y', 'ą' => 'a', 'ł' => 'l', - 'ų' => 'u', 'ů' => 'u', 'ş' => 's', 'ğ' => 'g', 'ļ' => 'l', 'ƒ' => 'f', 'ž' => 'z', - 'ẃ' => 'w', 'ḃ' => 'b', 'å' => 'a', 'ì' => 'i', 'ï' => 'i', 'ḋ' => 'd', 'ť' => 't', - 'ŗ' => 'r', 'ä' => 'ae', 'í' => 'i', 'ŕ' => 'r', 'ê' => 'e', 'ü' => 'ue', 'ò' => 'o', - 'ē' => 'e', 'ñ' => 'n', 'ń' => 'n', 'ĥ' => 'h', 'ĝ' => 'g', 'đ' => 'd', 'ĵ' => 'j', - 'ÿ' => 'y', 'ũ' => 'u', 'ŭ' => 'u', 'ư' => 'u', 'ţ' => 't', 'ý' => 'y', 'ő' => 'o', - 'â' => 'a', 'ľ' => 'l', 'ẅ' => 'w', 'ż' => 'z', 'ī' => 'i', 'ã' => 'a', 'ġ' => 'g', - 'ṁ' => 'm', 'ō' => 'o', 'ĩ' => 'i', 'ù' => 'u', 'į' => 'i', 'ź' => 'z', 'á' => 'a', - 'û' => 'u', 'þ' => 'th', 'ð' => 'dh', 'æ' => 'ae', 'µ' => 'u', -); - -/** - * UTF-8 lookup table for upper case accented letters - * - * This lookuptable defines replacements for accented characters from the ASCII-7 - * range. This are upper case letters only. - * - * @author Andreas Gohr <an...@sp...> - * @see utf8_deaccent() - */ -$UTF8_UPPER_ACCENTS = array( - 'À' => 'A', 'Ô' => 'O', 'Ď' => 'D', 'Ḟ' => 'F', 'Ë' => 'E', 'Š' => 'S', 'Ơ' => 'O', - 'Ă' => 'A', 'Ř' => 'R', 'Ț' => 'T', 'Ň' => 'N', 'Ā' => 'A', 'Ķ' => 'K', - 'Ŝ' => 'S', 'Ỳ' => 'Y', 'Ņ' => 'N', 'Ĺ' => 'L', 'Ħ' => 'H', 'Ṗ' => 'P', 'Ó' => 'O', - 'Ú' => 'U', 'Ě' => 'E', 'É' => 'E', 'Ç' => 'C', 'Ẁ' => 'W', 'Ċ' => 'C', 'Õ' => 'O', - 'Ṡ' => 'S', 'Ø' => 'O', 'Ģ' => 'G', 'Ŧ' => 'T', 'Ș' => 'S', 'Ė' => 'E', 'Ĉ' => 'C', - 'Ś' => 'S', 'Î' => 'I', 'Ű' => 'U', 'Ć' => 'C', 'Ę' => 'E', 'Ŵ' => 'W', 'Ṫ' => 'T', - 'Ū' => 'U', 'Č' => 'C', 'Ö' => 'Oe', 'È' => 'E', 'Ŷ' => 'Y', 'Ą' => 'A', 'Ł' => 'L', - 'Ų' => 'U', 'Ů' => 'U', 'Ş' => 'S', 'Ğ' => 'G', 'Ļ' => 'L', 'Ƒ' => 'F', 'Ž' => 'Z', - 'Ẃ' => 'W', 'Ḃ' => 'B', 'Å' => 'A', 'Ì' => 'I', 'Ï' => 'I', 'Ḋ' => 'D', 'Ť' => 'T', - 'Ŗ' => 'R', 'Ä' => 'Ae', 'Í' => 'I', 'Ŕ' => 'R', 'Ê' => 'E', 'Ü' => 'Ue', 'Ò' => 'O', - 'Ē' => 'E', 'Ñ' => 'N', 'Ń' => 'N', 'Ĥ' => 'H', 'Ĝ' => 'G', 'Đ' => 'D', 'Ĵ' => 'J', - 'Ÿ' => 'Y', 'Ũ' => 'U', 'Ŭ' => 'U', 'Ư' => 'U', 'Ţ' => 'T', 'Ý' => 'Y', 'Ő' => 'O', - 'Â' => 'A', 'Ľ' => 'L', 'Ẅ' => 'W', 'Ż' => 'Z', 'Ī' => 'I', 'Ã' => 'A', 'Ġ' => 'G', - 'Ṁ' => 'M', 'Ō' => 'O', 'Ĩ' => 'I', 'Ù' => 'U', 'Į' => 'I', 'Ź' => 'Z', 'Á' => 'A', - 'Û' => 'U', 'Þ' => 'Th', 'Ð' => 'Dh', 'Æ' => 'Ae', -); - -/** - * UTF-8 array of common special characters - * - * This array should contain all special characters (not a letter or digit) - * defined in the various local charsets - it's not a complete list of non-alphanum - * characters in UTF-8. It's not perfect but should match most cases of special - * chars. - * - * The controlchars 0x00 to 0x19 are _not_ included in this array. The space 0x20 is! - * These chars are _not_ in the array either: _ (0x5f), : 0x3a, . 0x2e, - 0x2d, * 0x2a - * - * @author Andreas Gohr <an...@sp...> - * @see utf8_stripspecials() - */ -$UTF8_SPECIAL_CHARS = array( - 0x001a, 0x001b, 0x001c, 0x001d, 0x001e, 0x001f, 0x0020, 0x0021, 0x0022, 0x0023, - 0x0024, 0x0025, 0x0026, 0x0027, 0x0028, 0x0029, 0x002b, 0x002c, - 0x002f, 0x003b, 0x003c, 0x003d, 0x003e, 0x003f, 0x0040, 0x005b, - 0x005c, 0x005d, 0x005e, 0x0060, 0x007b, 0x007c, 0x007d, 0x007e, - 0x007f, 0x0080, 0x0081, 0x0082, 0x0083, 0x0084, 0x0085, 0x0086, 0x0087, 0x0088, - 0x0089, 0x008a, 0x008b, 0x008c, 0x008d, 0x008e, 0x008f, 0x0090, 0x0091, 0x0092, - 0x0093, 0x0094, 0x0095, 0x0096, 0x0097, 0x0098, 0x0099, 0x009a, 0x009b, 0x009c, - 0x009d, 0x009e, 0x009f, 0x00a0, 0x00a1, 0x00a2, 0x00a3, 0x00a4, 0x00a5, 0x00a6, - 0x00a7, 0x00a8, 0x00a9, 0x00aa, 0x00ab, 0x00ac, 0x00ad, 0x00ae, 0x00af, 0x00b0, - 0x00b1, 0x00b2, 0x00b3, 0x00b4, 0x00b5, 0x00b6, 0x00b7, 0x00b8, 0x00b9, 0x00ba, - 0x00bb, 0x00bc, 0x00bd, 0x00be, 0x00bf, 0x00d7, 0x00f7, 0x02c7, 0x02d8, 0x02d9, - 0x02da, 0x02db, 0x02dc, 0x02dd, 0x0300, 0x0301, 0x0303, 0x0309, 0x0323, 0x0384, - 0x0385, 0x0387, 0x03b2, 0x03c6, 0x03d1, 0x03d2, 0x03d5, 0x03d6, 0x05b0, 0x05b1, - 0x05b2, 0x05b3, 0x05b4, 0x05b5, 0x05b6, 0x05b7, 0x05b8, 0x05b9, 0x05bb, 0x05bc, - 0x05bd, 0x05be, 0x05bf, 0x05c0, 0x05c1, 0x05c2, 0x05c3, 0x05f3, 0x05f4, 0x060c, - 0x061b, 0x061f, 0x0640, 0x064b, 0x064c, 0x064d, 0x064e, 0x064f, 0x0650, 0x0651, - 0x0652, 0x066a, 0x0e3f, 0x200c, 0x200d, 0x200e, 0x200f, 0x2013, 0x2014, 0x2015, - 0x2017, 0x2018, 0x2019, 0x201a, 0x201c, 0x201d, 0x201e, 0x2020, 0x2021, 0x2022, - 0x2026, 0x2030, 0x2032, 0x2033, 0x2039, 0x203a, 0x2044, 0x20a7, 0x20aa, 0x20ab, - 0x20ac, 0x2116, 0x2118, 0x2122, 0x2126, 0x2135, 0x2190, 0x2191, 0x2192, 0x2193, - 0x2194, 0x2195, 0x21b5, 0x21d0, 0x21d1, 0x21d2, 0x21d3, 0x21d4, 0x2200, 0x2202, - 0x2203, 0x2205, 0x2206, 0x2207, 0x2208, 0x2209, 0x220b, 0x220f, 0x2211, 0x2212, - 0x2215, 0x2217, 0x2219, 0x221a, 0x221d, 0x221e, 0x2220, 0x2227, 0x2228, 0x2229, - 0x222a, 0x222b, 0x2234, 0x223c, 0x2245, 0x2248, 0x2260, 0x2261, 0x2264, 0x2265, - 0x2282, 0x2283, 0x2284, 0x2286, 0x2287, 0x2295, 0x2297, 0x22a5, 0x22c5, 0x2310, - 0x2320, 0x2321, 0x2329, 0x232a, 0x2469, 0x2500, 0x2502, 0x250c, 0x2510, 0x2514, - 0x2518, 0x251c, 0x2524, 0x252c, 0x2534, 0x253c, 0x2550, 0x2551, 0x2552, 0x2553, - 0x2554, 0x2555, 0x2556, 0x2557, 0x2558, 0x2559, 0x255a, 0x255b, 0x255c, 0x255d, - 0x255e, 0x255f, 0x2560, 0x2561, 0x2562, 0x2563, 0x2564, 0x2565, 0x2566, 0x2567, - 0x2568, 0x2569, 0x256a, 0x256b, 0x256c, 0x2580, 0x2584, 0x2588, 0x258c, 0x2590, - 0x2591, 0x2592, 0x2593, 0x25a0, 0x25b2, 0x25bc, 0x25c6, 0x25ca, 0x25cf, 0x25d7, - 0x2605, 0x260e, 0x261b, 0x261e, 0x2660, 0x2663, 0x2665, 0x2666, 0x2701, 0x2702, - 0x2703, 0x2704, 0x2706, 0x2707, 0x2708, 0x2709, 0x270c, 0x270d, 0x270e, 0x270f, - 0x2710, 0x2711, 0x2712, 0x2713, 0x2714, 0x2715, 0x2716, 0x2717, 0x2718, 0x2719, - 0x271a, 0x271b, 0x271c, 0x271d, 0x271e, 0x271f, 0x2720, 0x2721, 0x2722, 0x2723, - 0x2724, 0x2725, 0x2726, 0x2727, 0x2729, 0x272a, 0x272b, 0x272c, 0x272d, 0x272e, - 0x272f, 0x2730, 0x2731, 0x2732, 0x2733, 0x2734, 0x2735, 0x2736, 0x2737, 0x2738, - 0x2739, 0x273a, 0x273b, 0x273c, 0x273d, 0x273e, 0x273f, 0x2740, 0x2741, 0x2742, - 0x2743, 0x2744, 0x2745, 0x2746, 0x2747, 0x2748, 0x2749, 0x274a, 0x274b, 0x274d, - 0x274f, 0x2750, 0x2751, 0x2752, 0x2756, 0x2758, 0x2759, 0x275a, 0x275b, 0x275c, - 0x275d, 0x275e, 0x2761, 0x2762, 0x2763, 0x2764, 0x2765, 0x2766, 0x2767, 0x277f, - 0x2789, 0x2793, 0x2794, 0x2798, 0x2799, 0x279a, 0x279b, 0x279c, 0x279d, 0x279e, - 0x279f, 0x27a0, 0x27a1, 0x27a2, 0x27a3, 0x27a4, 0x27a5, 0x27a6, 0x27a7, 0x27a8, - 0x27a9, 0x27aa, 0x27ab, 0x27ac, 0x27ad, 0x27ae, 0x27af, 0x27b1, 0x27b2, 0x27b3, - 0x27b4, 0x27b5, 0x27b6, 0x27b7, 0x27b8, 0x27b9, 0x27ba, 0x27bb, 0x27bc, 0x27bd, - 0x27be, 0xf6d9, 0xf6da, 0xf6db, 0xf8d7, 0xf8d8, 0xf8d9, 0xf8da, 0xf8db, 0xf8dc, - 0xf8dd, 0xf8de, 0xf8df, 0xf8e0, 0xf8e1, 0xf8e2, 0xf8e3, 0xf8e4, 0xf8e5, 0xf8e6, - 0xf8e7, 0xf8e8, 0xf8e9, 0xf8ea, 0xf8eb, 0xf8ec, 0xf8ed, 0xf8ee, 0xf8ef, 0xf8f0, - 0xf8f1, 0xf8f2, 0xf8f3, 0xf8f4, 0xf8f5, 0xf8f6, 0xf8f7, 0xf8f8, 0xf8f9, 0xf8fa, - 0xf8fb, 0xf8fc, 0xf8fd, 0xf8fe, 0xfe7c, 0xfe7d, -); - -/** - * Romanization lookup table - * - * This lookup tables provides a way to transform strings written in a language - * different from the ones based upon latin letters into plain ASCII. - * - * Please note: this is not a scientific transliteration table. It only works - * oneway from nonlatin to ASCII and it works by simple character replacement - * only. Specialities of each language are not supported. - * - * @author Andreas Gohr <an...@sp...> - * @author Vitaly Blokhin <vi...@vi...> - * @link http://www.uconv.com/translit.htm - * @author Bisqwit <bi...@ik...> - * @link http://kanjidict.stc.cx/hiragana.php?src=2 - * @link http://www.translatum.gr/converter/greek-transliteration.htm - * @link http://en.wikipedia.org/wiki/Royal_Thai_General_System_of_Transcription - * @link http://www.btranslations.com/resources/romanization/korean.asp - */ -$UTF8_ROMANIZATION = array( - //russian cyrillic - 'а'=>'a','А'=>'A','б'=>'b','Б'=>'B','в'=>'v','В'=>'V','г'=>'g','Г'=>'G', - 'д'=>'d','Д'=>'D','е'=>'e','Е'=>'E','ё'=>'jo','Ё'=>'Jo','ж'=>'zh','Ж'=>'Zh', - 'з'=>'z','З'=>'Z','и'=>'i','И'=>'I','й'=>'j','Й'=>'J','к'=>'k','К'=>'K', - 'л'=>'l','Л'=>'L','м'=>'m','М'=>'M','н'=>'n','Н'=>'N','о'=>'o','О'=>'O', - 'п'=>'p','П'=>'P','р'=>'r','Р'=>'R','с'=>'s','С'=>'S','т'=>'t','Т'=>'T', - 'у'=>'u','У'=>'U','ф'=>'f','Ф'=>'F','х'=>'x','Х'=>'X','ц'=>'c','Ц'=>'C', - 'ч'=>'ch','Ч'=>'Ch','ш'=>'sh','Ш'=>'Sh','щ'=>'th','Щ'=>'Th','ъ'=>'qh', - 'Ъ'=>'Qh','ы'=>'y','Ы'=>'Y','ь'=>'q','Ь'=>'Q','э'=>'eh','Э'=>'Eh','ю'=>'ju', - 'Ю'=>'Ju','я'=>'ja','Я'=>'Ja', - // Ukrainian cyrillic - 'Ґ'=>'Gh','ґ'=>'gh','Є'=>'Je','є'=>'je','І'=>'I','і'=>'i','Ї'=>'Ji','ї'=>'ji', - // Georgian - 'ა'=>'a','ბ'=>'b','გ'=>'g','დ'=>'d','ე'=>'e','ვ'=>'v','ზ'=>'z','თ'=>'th', - 'ი'=>'i','კ'=>'p','ლ'=>'l','მ'=>'m','ნ'=>'n','ო'=>'o','პ'=>'p','ჟ'=>'zh', - 'რ'=>'r','ს'=>'s','ტ'=>'t','უ'=>'u','ფ'=>'ph','ქ'=>'kh','ღ'=>'gh','ყ'=>'q', - 'შ'=>'sh','ჩ'=>'ch','ც'=>'c','ძ'=>'dh','წ'=>'w','ჭ'=>'j','ხ'=>'x','ჯ'=>'jh', - 'ჰ'=>'xh', - //Sanskrit - 'अ'=>'a','आ'=>'ah','इ'=>'i','ई'=>'ih','उ'=>'u','ऊ'=>'uh','ऋ'=>'ry', - 'ॠ'=>'ryh','ऌ'=>'ly','ॡ'=>'lyh','ए'=>'e','ऐ'=>'ay','ओ'=>'o','औ'=>'aw', - 'अं'=>'amh','अः'=>'aq','क'=>'k','ख'=>'kh','ग'=>'g','घ'=>'gh','ङ'=>'nh', - 'च'=>'c','छ'=>'ch','ज'=>'j','झ'=>'jh','ञ'=>'ny','ट'=>'tq','ठ'=>'tqh', - 'ड'=>'dq','ढ'=>'dqh','ण'=>'nq','त'=>'t','थ'=>'th','द'=>'d','ध'=>'dh', - 'न'=>'n','प'=>'p','फ'=>'ph','ब'=>'b','भ'=>'bh','म'=>'m','य'=>'z','र'=>'r', - 'ल'=>'l','व'=>'v','श'=>'sh','ष'=>'sqh','स'=>'s','ह'=>'x', - //Hebrew - 'ב'=>'a','ג'=>'b','ד'=>'g','ה'=>'d','ו'=>'x','ז'=>'v','ח'=>'kh','ט'=>'th', - 'י'=>'y','ך'=>'k','כ'=>'k','ל'=>'l','ם'=>'m','מ'=>'m','ן'=>'n','נ'=>'n', - 'ס'=>'s','ע'=>'ah','ף'=>'p','פ'=>'p','ץ'=>'c','צ'=>'c','ק'=>'q','ר'=>'r', - 'ש'=>'sh','ת'=>'t', - //Arabic - 'ا'=>'a','ب'=>'b','ت'=>'t','ث'=>'th','ج'=>'g','ح'=>'xh','خ'=>'x','د'=>'d', - 'ذ'=>'dh','ر'=>'r','ز'=>'z','س'=>'s','ش'=>'sh','ص'=>'s\'','ض'=>'d\'', - 'ط'=>'t\'','ظ'=>'z\'','ع'=>'y','غ'=>'gh','ف'=>'f','ق'=>'q','ك'=>'k', - 'ل'=>'l','م'=>'m','ن'=>'n','ه'=>'x\'','و'=>'u','ي'=>'i', - - // Japanese hiragana - 'あ'=>'a','え'=>'e','い'=>'i','お'=>'o','う'=>'u','ば'=>'ba','べ'=>'be', - 'び'=>'bi','ぼ'=>'bo','ぶ'=>'bu','し'=>'ci','だ'=>'da','で'=>'de','ぢ'=>'di', - 'ど'=>'do','づ'=>'du','ふぁ'=>'fa','ふぇ'=>'fe','ふぃ'=>'fi','ふぉ'=>'fo', - 'ふ'=>'fu','が'=>'ga','げ'=>'ge','ぎ'=>'gi','ご'=>'go','ぐ'=>'gu','は'=>'ha', - 'へ'=>'he','ひ'=>'hi','ほ'=>'ho','ふ'=>'hu','じゃ'=>'ja','じぇ'=>'je', - 'じ'=>'ji','じょ'=>'jo','じゅ'=>'ju','か'=>'ka','け'=>'ke','き'=>'ki', - 'こ'=>'ko','く'=>'ku','ら'=>'la','れ'=>'le','り'=>'li','ろ'=>'lo','る'=>'lu', - 'ま'=>'ma','め'=>'me','み'=>'mi','も'=>'mo','む'=>'mu','な'=>'na','ね'=>'ne', - 'に'=>'ni','の'=>'no','ぬ'=>'nu','ぱ'=>'pa','ぺ'=>'pe','ぴ'=>'pi','ぽ'=>'po', - 'ぷ'=>'pu','ら'=>'ra','れ'=>'re','り'=>'ri','ろ'=>'ro','る'=>'ru','さ'=>'sa', - 'せ'=>'se','し'=>'si','そ'=>'so','す'=>'su','た'=>'ta','て'=>'te','ち'=>'ti', - 'と'=>'to','つ'=>'tu','ヴぁ'=>'va','ヴぇ'=>'ve','ヴぃ'=>'vi','ヴぉ'=>'vo', - 'ヴ'=>'vu','わ'=>'wa','うぇ'=>'we','うぃ'=>'wi','を'=>'wo','や'=>'ya','いぇ'=>'ye', - 'い'=>'yi','よ'=>'yo','ゆ'=>'yu','ざ'=>'za','ぜ'=>'ze','じ'=>'zi','ぞ'=>'zo', - 'ず'=>'zu','びゃ'=>'bya','びぇ'=>'bye','びぃ'=>'byi','びょ'=>'byo','びゅ'=>'byu', - 'ちゃ'=>'cha','ちぇ'=>'che','ち'=>'chi','ちょ'=>'cho','ちゅ'=>'chu','ちゃ'=>'cya', - 'ちぇ'=>'cye','ちぃ'=>'cyi','ちょ'=>'cyo','ちゅ'=>'cyu','でゃ'=>'dha','でぇ'=>'dhe', - 'でぃ'=>'dhi','でょ'=>'dho','でゅ'=>'dhu','どぁ'=>'dwa','どぇ'=>'dwe','どぃ'=>'dwi', - 'どぉ'=>'dwo','どぅ'=>'dwu','ぢゃ'=>'dya','ぢぇ'=>'dye','ぢぃ'=>'dyi','ぢょ'=>'dyo', - 'ぢゅ'=>'dyu','ぢ'=>'dzi','ふぁ'=>'fwa','ふぇ'=>'fwe','ふぃ'=>'fwi','ふぉ'=>'fwo', - 'ふぅ'=>'fwu','ふゃ'=>'fya','ふぇ'=>'fye','ふぃ'=>'fyi','ふょ'=>'fyo','ふゅ'=>'fyu', - 'ぎゃ'=>'gya','ぎぇ'=>'gye','ぎぃ'=>'gyi','ぎょ'=>'gyo','ぎゅ'=>'gyu','ひゃ'=>'hya', - 'ひぇ'=>'hye','ひぃ'=>'hyi','ひょ'=>'hyo','ひゅ'=>'hyu','じゃ'=>'jya','じぇ'=>'jye', - 'じぃ'=>'jyi','じょ'=>'jyo','じゅ'=>'jyu','きゃ'=>'kya','きぇ'=>'kye','きぃ'=>'kyi', - 'きょ'=>'kyo','きゅ'=>'kyu','りゃ'=>'lya','りぇ'=>'lye','りぃ'=>'lyi','りょ'=>'lyo', - 'りゅ'=>'lyu','みゃ'=>'mya','みぇ'=>'mye','みぃ'=>'myi','みょ'=>'myo','みゅ'=>'myu', - 'ん'=>'n','にゃ'=>'nya','にぇ'=>'nye','にぃ'=>'nyi','にょ'=>'nyo','にゅ'=>'nyu', - 'ぴゃ'=>'pya','ぴぇ'=>'pye','ぴぃ'=>'pyi','ぴょ'=>'pyo','ぴゅ'=>'pyu','りゃ'=>'rya', - 'りぇ'=>'rye','りぃ'=>'ryi','りょ'=>'ryo','りゅ'=>'ryu','しゃ'=>'sha','しぇ'=>'she', - 'し'=>'shi','しょ'=>'sho','しゅ'=>'shu','すぁ'=>'swa','すぇ'=>'swe','すぃ'=>'swi', - 'すぉ'=>'swo','すぅ'=>'swu','しゃ'=>'sya','しぇ'=>'sye','しぃ'=>'syi','しょ'=>'syo', - 'しゅ'=>'syu','てゃ'=>'tha','てぇ'=>'the','てぃ'=>'thi','てょ'=>'tho','てゅ'=>'thu', - 'つゃ'=>'tsa','つぇ'=>'tse','つぃ'=>'tsi','つょ'=>'tso','つ'=>'tsu','とぁ'=>'twa', - 'とぇ'=>'twe','とぃ'=>'twi','とぉ'=>'two','とぅ'=>'twu','ちゃ'=>'tya','ちぇ'=>'tye', - 'ちぃ'=>'tyi','ちょ'=>'tyo','ちゅ'=>'tyu','ヴゃ'=>'vya','ヴぇ'=>'vye','ヴぃ'=>'vyi', - 'ヴょ'=>'vyo','ヴゅ'=>'vyu','うぁ'=>'wha','うぇ'=>'whe','うぃ'=>'whi','うぉ'=>'who', - 'うぅ'=>'whu','ゑ'=>'wye','ゐ'=>'wyi','じゃ'=>'zha','じぇ'=>'zhe','じぃ'=>'zhi', - 'じょ'=>'zho','じゅ'=>'zhu','じゃ'=>'zya','じぇ'=>'zye','じぃ'=>'zyi','じょ'=>'zyo', - 'じゅ'=>'zyu', - // Japanese katakana - 'ア'=>'a','エ'=>'e','イ'=>'i','オ'=>'o','ウ'=>'u','バ'=>'ba','ベ'=>'be','ビ'=>'bi', - 'ボ'=>'bo','ブ'=>'bu','シ'=>'ci','ダ'=>'da','デ'=>'de','ヂ'=>'di','ド'=>'do', - 'ヅ'=>'du','ファ'=>'fa','フェ'=>'fe','フィ'=>'fi','フォ'=>'fo','フ'=>'fu','ガ'=>'ga', - 'ゲ'=>'ge','ギ'=>'gi','ゴ'=>'go','グ'=>'gu','ハ'=>'ha','ヘ'=>'he','ヒ'=>'hi','ホ'=>'ho', - 'フ'=>'hu','ジャ'=>'ja','ジェ'=>'je','ジ'=>'ji','ジョ'=>'jo','ジュ'=>'ju','カ'=>'ka', - 'ケ'=>'ke','キ'=>'ki','コ'=>'ko','ク'=>'ku','ラ'=>'la','レ'=>'le','リ'=>'li','ロ'=>'lo', - 'ル'=>'lu','マ'=>'ma','メ'=>'me','ミ'=>'mi','モ'=>'mo','ム'=>'mu','ナ'=>'na','ネ'=>'ne', - 'ニ'=>'ni','ノ'=>'no','ヌ'=>'nu','パ'=>'pa','ペ'=>'pe','ピ'=>'pi','ポ'=>'po','プ'=>'pu', - 'ラ'=>'ra','レ'=>'re','リ'=>'ri','ロ'=>'ro','ル'=>'ru','サ'=>'sa','セ'=>'se','シ'=>'si', - 'ソ'=>'so','ス'=>'su','タ'=>'ta','テ'=>'te','チ'=>'ti','ト'=>'to','ツ'=>'tu','ヴァ'=>'va', - 'ヴェ'=>'ve','ヴィ'=>'vi','ヴォ'=>'vo','ヴ'=>'vu','ワ'=>'wa','ウェ'=>'we','ウィ'=>'wi', - 'ヲ'=>'wo','ヤ'=>'ya','イェ'=>'ye','イ'=>'yi','ヨ'=>'yo','ユ'=>'yu','ザ'=>'za','ゼ'=>'ze', - 'ジ'=>'zi','ゾ'=>'zo','ズ'=>'zu','ビャ'=>'bya','ビェ'=>'bye','ビィ'=>'byi','ビョ'=>'byo', - 'ビュ'=>'byu','チャ'=>'cha','チェ'=>'che','チ'=>'chi','チョ'=>'cho','チュ'=>'chu', - 'チャ'=>'cya','チェ'=>'cye','チィ'=>'cyi','チョ'=>'cyo','チュ'=>'cyu','デャ'=>'dha', - 'デェ'=>'dhe','ディ'=>'dhi','デョ'=>'dho','デュ'=>'dhu','ドァ'=>'dwa','ドェ'=>'dwe', - 'ドィ'=>'dwi','ドォ'=>'dwo','ドゥ'=>'dwu','ヂャ'=>'dya','ヂェ'=>'dye','ヂィ'=>'dyi', - 'ヂョ'=>'dyo','ヂュ'=>'dyu','ヂ'=>'dzi','ファ'=>'fwa','フェ'=>'fwe','フィ'=>'fwi', - 'フォ'=>'fwo','フゥ'=>'fwu','フャ'=>'fya','フェ'=>'fye','フィ'=>'fyi','フョ'=>'fyo', - 'フュ'=>'fyu','ギャ'=>'gya','ギェ'=>'gye','ギィ'=>'gyi','ギョ'=>'gyo','ギュ'=>'gyu', - 'ヒャ'=>'hya','ヒェ'=>'hye','ヒィ'=>'hyi','ヒョ'=>'hyo','ヒュ'=>'hyu','ジャ'=>'jya', - 'ジェ'=>'jye','ジィ'=>'jyi','ジョ'=>'jyo','ジュ'=>'jyu','キャ'=>'kya','キェ'=>'kye', - 'キィ'=>'kyi','キョ'=>'kyo','キュ'=>'kyu','リャ'=>'lya','リェ'=>'lye','リィ'=>'lyi', - 'リョ'=>'lyo','リュ'=>'lyu','ミャ'=>'mya','ミェ'=>'mye','ミィ'=>'myi','ミョ'=>'myo', - 'ミュ'=>'myu','ン'=>'n','ニャ'=>'nya','ニェ'=>'nye','ニィ'=>'nyi','ニョ'=>'nyo', - 'ニュ'=>'nyu','ピャ'=>'pya','ピェ'=>'pye','ピィ'=>'pyi','ピョ'=>'pyo','ピュ'=>'pyu', - 'リャ'=>'rya','リェ'=>'rye','リィ'=>'ryi','リョ'=>'ryo','リュ'=>'ryu','シャ'=>'sha', - 'シェ'=>'she','シ'=>'shi','ショ'=>'sho','シュ'=>'shu','スァ'=>'swa','スェ'=>'swe', - 'スィ'=>'swi','スォ'=>'swo','スゥ'=>'swu','シャ'=>'sya','シェ'=>'sye','シィ'=>'syi', - 'ショ'=>'syo','シュ'=>'syu','テャ'=>'tha','テェ'=>'the','ティ'=>'thi','テョ'=>'tho', - 'テュ'=>'thu','ツャ'=>'tsa','ツェ'=>'tse','ツィ'=>'tsi','ツョ'=>'tso','ツ'=>'tsu', - 'トァ'=>'twa','トェ'=>'twe','トィ'=>'twi','トォ'=>'two','トゥ'=>'twu','チャ'=>'tya', - 'チェ'=>'tye','チィ'=>'tyi','チョ'=>'tyo','チュ'=>'tyu','ヴャ'=>'vya','ヴェ'=>'vye', - 'ヴィ'=>'vyi','ヴョ'=>'vyo','ヴュ'=>'vyu','ウァ'=>'wha','ウェ'=>'whe','ウィ'=>'whi', - 'ウォ'=>'who','ウゥ'=>'whu','ヱ'=>'wye','ヰ'=>'wyi','ジャ'=>'zha','ジェ'=>'zhe', - 'ジィ'=>'zhi','ジョ'=>'zho','ジュ'=>'zhu','ジャ'=>'zya','ジェ'=>'zye','ジィ'=>'zyi', - 'ジョ'=>'zyo','ジュ'=>'zyu', - - // "Greeklish" - 'Γ'=>'G','Δ'=>'E','Θ'=>'Th','Λ'=>'L','Ξ'=>'X','Π'=>'P','Σ'=>'S','Φ'=>'F','Ψ'=>'Ps', - 'γ'=>'g','δ'=>'e','θ'=>'th','λ'=>'l','ξ'=>'x','π'=>'p','σ'=>'s','φ'=>'f','ψ'=>'ps', - - // Thai - 'ก'=>'k','ข'=>'kh','ฃ'=>'kh','ค'=>'kh','ฅ'=>'kh','ฆ'=>'kh','ง'=>'ng','จ'=>'ch', - 'ฉ'=>'ch','ช'=>'ch','ซ'=>'s','ฌ'=>'ch','ญ'=>'y','ฎ'=>'d','ฏ'=>'t','ฐ'=>'th', - 'ฑ'=>'d','ฒ'=>'th','ณ'=>'n','ด'=>'d','ต'=>'t','ถ'=>'th','ท'=>'th','ธ'=>'th', - 'น'=>'n','บ'=>'b','ป'=>'p','ผ'=>'ph','ฝ'=>'f','พ'=>'ph','ฟ'=>'f','ภ'=>'ph', - 'ม'=>'m','ย'=>'y','ร'=>'r','ฤ'=>'rue','ฤๅ'=>'rue','ล'=>'l','ฦ'=>'lue', - 'ฦๅ'=>'lue','ว'=>'w','ศ'=>'s','ษ'=>'s','ส'=>'s','ห'=>'h','ฬ'=>'l','ฮ'=>'h', - 'ะ'=>'a','–ั'=>'a','รร'=>'a','า'=>'a','รร'=>'an','ำ'=>'am','–ิ'=>'i','–ี'=>'i', - '–ึ'=>'ue','–ื'=>'ue','–ุ'=>'u','–ู'=>'u','เะ'=>'e','เ–็'=>'e','เ'=>'e','แะ'=>'ae', - 'แ'=>'ae','โะ'=>'o','โ'=>'o','เาะ'=>'o','อ'=>'o','เอะ'=>'oe','เ–ิ'=>'oe', - 'เอ'=>'oe','เ–ียะ'=>'ia','เ–ีย'=>'ia','เ–ือะ'=>'uea','เ–ือ'=>'uea','–ัวะ'=>'ua', - '–ัว'=>'ua','ว'=>'ua','ใ'=>'ai','ไ'=>'ai','–ัย'=>'ai','ไย'=>'ai','าย'=>'ai', - 'เา'=>'ao','าว'=>'ao','–ุย'=>'ui','โย'=>'oi','อย'=>'oi','เย'=>'oei','เ–ือย'=>'ueai', - 'วย'=>'uai','–ิว'=>'io','เ–็ว'=>'eo','เว'=>'eo','แ–็ว'=>'aeo','แว'=>'aeo', - 'เ–ียว'=>'iao', - - // Korean - 'ㄱ'=>'k','ㅋ'=>'kh','ㄲ'=>'kk','ㄷ'=>'t','ㅌ'=>'th','ㄸ'=>'tt','ㅂ'=>'p', - 'ㅍ'=>'ph','ㅃ'=>'pp','ㅈ'=>'c','ㅊ'=>'ch','ㅉ'=>'cc','ㅅ'=>'s','ㅆ'=>'ss', - 'ㅎ'=>'h','ㅇ'=>'ng','ㄴ'=>'n','ㄹ'=>'l','ㅁ'=>'m', 'ㅏ'=>'a','ㅓ'=>'e','ㅗ'=>'o', - 'ㅜ'=>'wu','ㅡ'=>'u','ㅣ'=>'i','ㅐ'=>'ay','ㅔ'=>'ey','ㅚ'=>'oy','ㅘ'=>'wa','ㅝ'=>'we', - 'ㅟ'=>'wi','ㅙ'=>'way','ㅞ'=>'wey','ㅢ'=>'uy','ㅑ'=>'ya','ㅕ'=>'ye','ㅛ'=>'oy', - 'ㅠ'=>'yu','ㅒ'=>'yay','ㅖ'=>'yey', -); - -//Setup VIM: ex: et ts=2 enc=utf-8 : - Added: trunk/lib/utf8/utf8_char2byte_pos.php =================================================================== --- trunk/lib/utf8/utf8_char2byte_pos.php (rev 0) +++ trunk/lib/utf8/utf8_char2byte_pos.php 2006-09-03 09:02:19 UTC (rev 727) @@ -0,0 +1,45 @@ +<?php + +/** + * Translates a character position into an 'absolute' byte position. + * Unit tested by Kasper. + * (http://phpxref.com/xref/moodle/lib/typo3/class.t3lib_cs.php.source.html.gz) + * + * @param string UTF-8 string + * @param integer Character position (negative values start from the end) + * @return integer Byte position + * @author Martin Kutschker <mar...@bl...> + */ +function utf8_char2byte_pos($str,$pos) { + $n = 0; // number of characters found + $p = abs($pos); // number of characters wanted + + if ($pos >= 0) { + $i = 0; + $d = 1; + } else { + $i = strlen($str)-1; + $d = -1; + } + + for( ; strlen($str{$i}) && $n<$p; $i+=$d) { + $c = (int)ord($str{$i}); + if (!($c & 0x80)) // single-byte (0xxxxxx) + $n++; + elseif (($c & 0xC0) == 0xC0) // multi-byte starting byte (11xxxxxx) + $n++; + } + if (!strlen($str{$i})) return false; // offset beyond string length + + if ($pos >= 0) { + // skip trailing multi-byte data bytes + while ((ord($str{$i}) & 0x80) && !(ord($str{$i}) & 0x40)) { $i++; } + } else { + // correct offset + $i++; + } + + return $i; +} + +?> \ No newline at end of file Added: trunk/lib/utf8/utf8_substr.php =================================================================== --- trunk/lib/utf8/utf8_substr.php (rev 0) +++ trunk/lib/utf8/utf8_substr.php 2006-09-03 09:02:19 UTC (rev 727) @@ -0,0 +1,41 @@ +<?php + +require_once dirname(__FILE__)."/utf8_char2byte_pos.php"; + +/** + * Returns a part of a UTF-8 string. + * Unit-tested by Kasper and works 100% like substr() / mb_substr() for full range of $start/$len + * (http://phpxref.com/xref/moodle/lib/typo3/class.t3lib_cs.php.source.html.gz) + * + * @param string UTF-8 string + * @param integer Start position (character position) + * @param integer Length (in characters) + * @return string The substring + * @see substr() + * @author Martin Kutschker <mar...@bl...> + */ +function utf8_substr($str,$start,$len=null) { + if (!strcmp($len,'0')) return ''; + + $byte_start = utf8_char2byte_pos($str,$start); + if ($byte_start === false) { + if ($start > 0) { + return false; // $start outside string length + } else { + $start = 0; + } + } + + $str = substr($str,$byte_start); + + if ($len!=null) { + $byte_end = utf8_char2byte_pos($str,$len); + if ($byte_end === false) // $len outside actual string length + return $len<0 ? '' : $str; // When length is less than zero and exceeds, then we return blank string. + else + return substr($str,0,$byte_end); + } + else return $str; +} + +?> \ No newline at end of file Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-09-02 21:20:15 UTC (rev 726) +++ trunk/src/phpfreechat.class.php 2006-09-03 09:02:19 UTC (rev 727) @@ -24,7 +24,7 @@ require_once dirname(__FILE__)."/pfcglobalconfig.class.php"; require_once dirname(__FILE__)."/pfcuserconfig.class.php"; require_once dirname(__FILE__)."/pfctemplate.class.php"; -require_once dirname(__FILE__)."/../lib/utf8/utf8.php"; +require_once dirname(__FILE__)."/../lib/utf8/utf8_substr.php"; /** * phpFreeChat is the entry point for developpers @@ -228,7 +228,7 @@ $c =& pfcGlobalConfig::Instance(); //$nickname = str_replace("\\", "", $nickname); // '\' is a forbidden charactere for nicknames $nickname = trim($nickname); - $nickname = @utf8_substr($nickname, 0, $c->max_nick_len); + $nickname = utf8_substr($nickname, 0, $c->max_nick_len); return $nickname; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-02 21:20:35
|
Revision: 726 http://svn.sourceforge.net/phpfreechat/?rev=726&view=rev Author: kerphi Date: 2006-09-02 14:20:15 -0700 (Sat, 02 Sep 2006) Log Message: ----------- Now display the errors when messages can't be written in the default file container Modified Paths: -------------- trunk/src/commands/notice.class.php trunk/src/commands/send.class.php trunk/src/containers/file.class.php Modified: trunk/src/commands/notice.class.php =================================================================== --- trunk/src/commands/notice.class.php 2006-09-02 20:42:09 UTC (rev 725) +++ trunk/src/commands/notice.class.php 2006-09-02 21:20:15 UTC (rev 726) @@ -21,7 +21,15 @@ { $container =& $c->getContainerInstance(); $msg = phpFreeChat::FilterSpecialChar($msg); - $container->write($recipient, $u->nick, "notice", $msg); + $res = $container->write($recipient, $u->nick, "notice", $msg); + if (is_array($res)) + { + $cmdp = $p; + $cmdp["param"] = implode(",",$res); + $cmd =& pfcCommand::Factory("error"); + $cmd->run($xml_reponse, $cmdp); + return; + } } if ($c->debug) pxlog("/notice ".$msg." (flag=".$flag.")", "chat", $c->getId()); } Modified: trunk/src/commands/send.class.php =================================================================== --- trunk/src/commands/send.class.php 2006-09-02 20:42:09 UTC (rev 725) +++ trunk/src/commands/send.class.php 2006-09-02 21:20:15 UTC (rev 726) @@ -79,6 +79,14 @@ { $container =& $c->getContainerInstance(); $msgid = $container->write($recipient, $nick, "send", $text); + if (is_array($msgid)) + { + $cmdp = $p; + $cmdp["param"] = implode(",",$msgid); + $cmd =& pfcCommand::Factory("error"); + $cmd->run($xml_reponse, $cmdp); + return; + } if ($c->debug) pxlog("/send ".$text." (a user just sent a message -> nick=".$u->nick.")", "chat", $c->getId()); // a message has been posted so : Modified: trunk/src/containers/file.class.php =================================================================== --- trunk/src/containers/file.class.php 2006-09-02 20:42:09 UTC (rev 725) +++ trunk/src/containers/file.class.php 2006-09-02 21:20:15 UTC (rev 726) @@ -459,9 +459,11 @@ $c->container_cfg_server_dir."/messages"; // check the messages directory exists $errors = @test_writable_dir($msg_dir, $chan."/messages"); + if (count($errors) > 0) return $errors; // an error occurs ? // request a unique id for this new message $msg_id = $this->_requestMsgId($chan); + if (is_array($msg_id)) return $msg_id; // an error occurs ? $msg_filename = $msg_dir."/".$msg_id; // format message @@ -706,6 +708,7 @@ $c->container_cfg_server_dir; // check the directory exists $errors = @test_writable_dir($chan_dir, $chan_dir); + if (count($errors) > 0) return $errors; $index_filename = $chan_dir . "/messages.index"; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-02 20:42:36
|
Revision: 725 http://svn.sourceforge.net/phpfreechat/?rev=725&view=rev Author: kerphi Date: 2006-09-02 13:42:09 -0700 (Sat, 02 Sep 2006) Log Message: ----------- Now the online documentation is automaticaly packaged by the release script (no more documentation misses). Modified Paths: -------------- trunk/misc/tarSource trunk/src/pfcglobalconfig.class.php Removed Paths: ------------- trunk/INSTALL.en trunk/INSTALL.fr trunk/README.en trunk/README.fr Deleted: trunk/INSTALL.en =================================================================== --- trunk/INSTALL.en 2006-09-02 20:38:40 UTC (rev 724) +++ trunk/INSTALL.en 2006-09-02 20:42:09 UTC (rev 725) @@ -1,298 +0,0 @@ - Install - - To install phpFreeChat you need: - - * A Web server (Apache, IIS, Xitami ...) with PHP (4 or 5) - * Write access on the Web server (SSH, FTP, or other) - - By default, you don't need a Mysql database because the system uses files - to store messages and nicknames. - - * Quick start - * Advanced configuration - - Quick start - - Using the setup (the easy way): - - 1. Download phpfreechat-x.x-setup.php[21] (lastest version) - 2. Upload the setup script on your server into a browsable directory - (public directory) - 3. Browse the script with your personnal browser, it should launch a - setup, then follow the steps ! - Tip: remove the setup when the install is finished for security - reason. - - Using the ziped archives (for those who havn't gzip module in their php): - - 1. Download phpfreechat-x.x.zip (or .tar.gz for linux users)[22] - (lastest version) - 2. Unzip the archive localy then upload the phpfreechat-x.x directory - on your server into a browsable directory (public directory). - Tip: if you have a SSH access I suggesto to untar the archives - directly on the server usign tar xzf phpfreechat-x.x.tar.gz command. - 3. Give the write rights to phpfreechat-x.x/data/public and - phpfreechat-x.x/data/private directories. - If you are using FTP: - CHMOD 777 phpfreechat-x.x/data/private - CHMOD 777 phpfreechat-x.x/data/public - - If you are using SSH: - chmod a+w phpfreechat-x.x/data/* - - 4. Browse the phpfreechat-x.x directory with your browser and enjoy ! - - Now you need surely to customize your chat. You can take a look at the - example scripts in the phpfreechat-x.x/demo directory. - - Here is the minimum script required for your chat to work (inspired from - demo1): - - <?php - - require_once "src/phpfreechat.class.php"; // adjust to your own path - $params["serverid"] = md5(__FILE__); // used to identify the chat - $chat = new phpFreeChat($params); - - ?> - <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> - <html> - <head> - <title>phpFreeChat demo</title> - <?php $chat->printJavascript(); ?> - <?php $chat->printStyle(); ?> - </head> - <body> - <?php $chat->printChat(); ?> - </body> - </html> - - Advanced configuration - - The chat is usable using the default configuration but a lot of options - can be tweaked to customize the chat. For exemple, to change the refresh - speed to 2 seconds, copy/paste this piece of code: - - <?php - - require_once "src/phpfreechat.class.php"; // adjust to your own path - $params["serverid"] = md5(__FILE__); - $params["refresh_delay"] = 2000; // 2000ms = 2s - $chat = new phpFreeChat($params); - - ?> - [... copy/paste here the above HTML codes ...] - - Another example, to set the initial nickname to "guest" (this can be - useful when the chat is integrated into a portal or a forum which - provides the login/password), copy/paste this piece of code: - - <?php - - require_once "src/phpfreechat.class.php"; // adjust to your own path - $params["serverid"] = md5(__FILE__); - $params["nick"] = "guest"; // it can be useful to take nicks from a database - $chat = new phpFreeChat($params); - - ?> - [... copy/paste here the above HTML codes ...] - - Now for the full parameters list: - - serverid - This is the only mandatory parameter. It is the chat server id, "its - IP" (comparable to the server host in IRC) used to identify the - chat. Two chat must have different serverid. If you don't know what - to write, just try : $params["serverid"] = md5(__FILE__); - nick - If you have already identified the user (forum, portal...) you can - force the user's nickname here, this will skip the "Please enter - your nickname" popup. - Warning : Nicknames must be encoded in UTF-8. For example, if you - get nicks from a databases where they are ISO-8859-1 encoded, you - must ocnvert it: $params["nick"] = iconv("ISO-8859-1", "UTF-8", - $bdd_nickname); (of course, change the $bdd_nickname parameter for - your needs) - ("" value by default, means users must choose a nickname when s/he - connect) - title - Used to change the chat title that is visible just above the - messages list. - ("My phpFreeChat" by default) - channel - Used to create a room. Technicaly this parameter is used to choose - the data (messages + nicknames) storage destination. For a better - explaination, see this FAQ entry[23]. - (auto-generated string based on the title parameter by default) - frozen_nick - Setting this to true will forbid the user to change his nickname - later. - (false value by default) - max_nick_len - This is the maximum nickname length, a longer nickname is forbidden. - ( 15 caracteres by default) - max_text_len - This is the maximum message length, a longer message is forbidden. - ( 250 characters by default) - refresh_delay - This is the time to wait between two refreshes. A refresh is a HTTP - request which asks the server if there are new messages to display. - If there are no new messages, then a empty HTTP response is returned. - ( 5000ms = 5s by default) - timeout - This is the time of inactivity to wait before to considere to - disconnecte user (in milliseconds). - ( 20000ms = 20s by default) - max_msg - This is the message history length. When a user connects, he can see - the history. The number of messages s/he can see is defined by this - (20 lines by default) - connect_at_startup - Setting this to false will oblige user to click on the connect - button if s/he wants to chat. - (true value by default, means when the chat web page is open, a - connection to the chat is automaticaly performed) - start_minimized - Setting it to true will start the chat minimized. - (false value by default) - height - Height of the chat area. - (440px by default) - width - Width of the chat area. - ("" by default, means it's given by the CSS) - shownotice - Setting this to 0 will disable nickname change notices and - connect/disconnect notices. Setting it to 1 will only disable - connect/disconnect notices. Setting it to 2 will show all notice - types. - (2 by default) - nickmarker - Setting it to false will disable nickname colorization. - (true value by default) - clock - Setting it to false will hide the date/hour column. - (true value by default) - openlinknewwindow - Setting it to true will add the target="_blank" into parsed links. - This attribute is used to open the followed link in a new window. - (true value by default) - showwhosonline - Used to show/hide online users at startup. - (true value by default) - showsmileys - Used to show/hide the smiley list at startup. - (true value by default) - btn_sh_whosonline - Used to display or not the showwhosonline button. - (true value by default) - btn_sh_smileys - Used to display or not the showsmileys button. - (true value by default) - themeurl - Used to specify the theme root url (useful for url rewriting) - (this parameter is automaticaly calculated by default) - themepath - The absolute theme directory path. Sub directories must contains - themes directories. - (dirname(__FILE__)."/../themes" by default) - theme - This parameter specifies which theme this chat will use. - ("default" by default) - language - Used to specify the chat labels language. Accepted values are i18n/* - sub directories names. - (by default this is the local server language) - output_encoding - Useful to set a sepcific encoding for chat labels. This is really - useful when the Web page embedding the chat is not UTF-8 encoded. - This parameter should be the same as the chat web page. - (UTF-8 by default ) - container_type - Used to specify the used container. For the moment, only a file - container has been written but in the future several containers - (mysql, irc, msn, jabber...) will surely be available. - ("File" by default) - server_script_path and server_script_url - Used to specify the script which will handle asynchronous request. - Very useful when the chat (client) script is resource consuming (ex: - forum or portal chat integration). server_script_url must point to - the server script browable url (useful when using url rewriting). - (by default these parameters are auto-calculated) - client_script_path and client_script_url - Used to specify the script path which display the chat and load - every JavaScript libraries (the client side). Useful when the php - configuration is uncommon, this option can be used to force the - automatic detection process. client_script_url must point to the - client script browable url (useful when using url rewriting). - (by default these parameters are auto-detected) - useie7 - Setting this to false will disable IE7[24] scripts used to improve - display for the crappy Internet Explorer. - (true value by default) - ie7path - Specify the IE7 path. It's useful if you allready have a IE7 library - installed and you want to save bytes on your server. - (dirname(__FILE__)."/../lib/IE7_0_9" by default) - jspath - Specify the javascript libraries path (md5, cookie ...). - (dirname(__FILE__)."/../lib/javascript" by default) - smartypath - Specify the Smarty[25] path. It's useful if you allready have a - Smarty library installed and you want to save bytes on your server. - (dirname(__FILE__)."/../lib/Smarty-2.6.7" by default) - usecsstidy - Setting this to false will disable CSSTidy library, css optimisation - (output size) will be disabled. - (false value by default because it make problems on strange server - configurations) - csstidypath - Specify the CSS Tidy[26] library path. It's useful if you allready - have a Smarty library installed and you want to save bytes on your - server. - (dirname(__FILE__)."/../lib/csstidy-1.1" by default) - xajaxpath - Specify the xajax[27] path. It's useful if you allready have a xajax - library installed and you want to save bytes on your server. - (dirname(__FILE__)."/../lib/xajax_0.2_stable" by default); - data_private_path - Used by the filesystem container to store chat data. Used by smarty - to store compiled templates. Tip: you can optimize your chat - performances, see this FAQ entry[28]. - (dirname(__FILE__)."/../data/private" by default) - data_public_path and data_public_url - This path must be reachable by your web server. IE7 scripts and - xajax JS compiled scripts will be stored here. data_public_url - parameter can be specified to help when url rewriting is used. - (dirname(__FILE__)."/../data/public" by default) - debug - For developers, setting it to true will activate logging and - debuging console. - (false value by default) - debugxajax - For developers, setting it to true will activate xajax js popup used - to trace communication between client and server during ajax - requests. Useful to discover hidden bugs like php warnings on a ajax - request. - (false value by default) - prefix - Used to prefix all javascript functions, css ids and css class in - order to avoid variables overlaps. - ("phpfreechat_" by default) - - \xA92006 phpFreeChat - - - --------------------------------------------------------------- -List of References - -Document's URL: http://www.phpfreechat.net/install.en.html -[23] faq.en.html#multiple-channels -[24] http://dean.edwards.name/IE7/ -[25] http://smarty.php.net/ -[26] http://csstidy.sourceforge.net/index.php -[27] http://www.xajaxproject.org/ -[28] faq.en.html#tmpfs - Deleted: trunk/INSTALL.fr =================================================================== --- trunk/INSTALL.fr 2006-09-02 20:38:40 UTC (rev 724) +++ trunk/INSTALL.fr 2006-09-02 20:42:09 UTC (rev 725) @@ -1,345 +0,0 @@ - Installation - - Vous avez besoin de : - - * Un serveur Web (apache, IIS ...) avec le module php (4 ou 5) - * Un acces en \xE9criture sur ce serveur Web (ssh, FTP ou autre) - - Par d\xE9faut, vous n'avez pas besoin d'une base de donn\xE9e Mysql car des - simples fichiers sont utilis\xE9s pour stoquer les informations. - - * En avant! - * Configuration avanc\xE9e - - En avant! - - Pour les feignants: - - 1. T\xE9l\xE9chargez le script d'installation auto-extractible : - phpfreechat-x.x-setup.php[21] (la derni\xE8re version de pr\xE9f\xE9rence) - 2. Uploadez le script dans un r\xE9pertoire accessible par votre - navigateur (r\xE9pertoire publique) - 3. Lancez votre navigateur et ex\xE9cutez le script d'installation que - vous venez d'uploader, ceci devrait lancer une interface - d'installation, suivez alors les \xE9tapes ! - Astuce : supprimez le scripte d'installation une fois termin\xE9 pour - des raisons de s\xE9curit\xE9. - - Pour les utilisateurs avanc\xE9s ou pour ceux qui n'ont pas gzip install\xE9 - sur leur serveur: - - 1. T\xE9l\xE9chargez l'archive zip (ou tag.gz pour les utilisateurs linux) : - phpfreechat-x.x.zip[22] (la derni\xE8re version de pr\xE9f\xE9rence) - 2. D\xE9compressez l'archive localement et uploadez le r\xE9sultat sur votre - serveur dans un r\xE9pertoire accessible par votre navigateur. - Astuce: si vous avez un acc\xE8s SSH, je vous conseil d'uploader - l'archive tar.gz puis de la d\xE9compresser directement sur le serveur - avec la commande tar xzf phpfreechat-x.x.tar.gz - 3. Donnez les droits en \xE9criture aux r\xE9pertoires - phpfreechat-x.x/data/public et phpfreechat-x.x/data/private - Si vous utilisez FTP, voici les commandes: - CHMOD 777 phpfreechat-x.x/data/private - CHMOD 777 phpfreechat-x.x/data/public - - Si vous utilisez SSH, voici les commandes: - chmod a+w phpfreechat-x.x/data/* - - 4. Pour terminer : lancez votre navigateur et ouvrez le r\xE9pertoire - phpfreechat-x.x sur votre serveur ! - - Vous d\xE9sirez certainement param\xE9trer votre propre chat, pour cela prenez - exemple sur les scriptes du r\xE9pertoire phpfreechat-x.x/demo. - - Voila le script minimum pour que le chat fonctionne (inspir\xE9 de demo1) : - - <?php - - require_once "src/phpfreechat.class.php"; // pensez \xE0 ajuster le chemin - $params["serverid"] = md5(__FILE__); // permet d'identifier ce chat - $chat = new phpFreeChat($params); - - ?> - <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" - "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> - <html> - <head> - <title>phpFreeChat demo</title> - <?php $chat->printJavascript(); ?> - <?php $chat->printStyle(); ?> - </head> - <body> - <?php $chat->printChat(); ?> - </body> - </html> - - Configuration avanc\xE9e - - Le chat fonctionne tr\xE8s bien en laissant les param\xE8tres par d\xE9faut mais - de nombreuses options peuvent \xEAtre r\xE9gl\xE9es. Par exemple, pour changer le - temps de rafraichissement \xE0 2 secondes (par d\xE9faut c'est 5 secondes), - voila ce qu'il faut faire : - - <?php - - require_once "src/phpfreechat.class.php"; // ajustez le chemin - $params["serverid"] = md5(__FILE__); - $params["refresh_delay"] = 2000; // 2000ms = 2s - $chat = new phpFreeChat($params); - - ?> - [... copiez/coller le code HTML vu plus haut ...] - - Un autre exemple: vous souhaitez que vos utilisateur n'entrent pas de - pseudonymes \xE0 leur arriv\xE9 sur le chat et qu'un pseudo "invit\xE9" leur oit - assign\xE9 automatiquement (ceci est tr\xE8s utile pour integrer le chat dans - un forum, un portail ou tout autre syst\xE8me o\xF9 l'utilisateur est d\xE9ja - authentifi\xE9), voila ce qu'il faut faire : - - <?php - - require_once "src/phpfreechat.class.php"; // ajustez le chemin - $params["serverid"] = md5(__FILE__); - $params["nick"] = "guest"; // ce pseudo peut-\xEAtre r\xE9cup\xE9r\xE9 depuis une base de donn\xE9es - $chat = new phpFreeChat($params); - - ?> - [... copiez/coller le code HTML vu plus haut ...] - - Maintenant voyons la liste exaustive des param\xE8tres : - - serverid - C'est leur seule param\xE8tre obligatoire. C'est l'identifiant du chat, - "son IP" (comparable \xE0 l'adresse (host) d'un serveur IRC) utilis\xE9 - pour diff\xE9rencer ce chat d'un autre. Deux chats doivent avoir des - serverid diff\xE9rents. Si vous ne savez pas quoi mettre, ceci - fonctionnera dans la majorit\xE9 des cas : $params["serverid"] = - md5(__FILE__); - nick - Ce param\xE8tre est tr\xE8s utile si vous connaissez \xE0 l'avance les - pseudonymes des utilisateurs, par exemple si vous souhaitez int\xE9grer - le chat \xE0 un forum ou a un portail qui poss\xE8de d\xE9j\xE0 un syst\xE8me - d'authentification. Il suffit de renseigner le pseudonyme de - l'utilisateur concern\xE9 dans cette option et l'utilisateur sera alors - automatiquement connect\xE9 avec son pseudonyme, il n'aura pas \xE0 - choisir son pseudo lors de la premi\xE8re connexion. - Attention : Les pseudonymes doivent \xEAtre encod\xE9s en UTF-8. Si par - exemple vos pseudo viennent d'une base de donn\xE9e o\xF9 ils sont encod\xE9s - en ISO-8859-1, vous devez les convertir : $params["nick"] = - iconv("ISO-8859-1", "UTF-8", $bdd_nickname); (bien sur changez la - variable $bdd_nickname \xE0 votre convenance) - Remarque : Cette option peut-\xEAtre utilis\xE9e conjointement \xE0 l'option - frozen_nick pour emp\xEAcher l'utilisateur de changer de nom. - ("" par d\xE9faut, signifie que les utilisateurs doivent choisir leur - pseudonymes quand ils se connectent) - title - Permet de changer le titre du chat, c'est \xE0 dire le texte qui - s'affiche en haut. - ("My phpFreeChat" est la valeur par d\xE9faut) - channel - Permet de cr\xE9er un salon. Techniquement, ce param\xE8tre permet de - choisir o\xF9 vont \xEAtre stock\xE9s les messages et les pseudonymes du - chat. Pour une explication plus d\xE9taill\xE9es voyez le paragraphe - suivant[23] dans la FAQ. - (par d\xE9faut, il est calcul\xE9 automatiquement \xE0 partir du title) - frozen_nick - Mettre cette option \xE0 true va tout simplement emp\xEAcher les - utilisateurs de changer leur pseudonymes. Cela sous entends que le - pseudonyme \xE0 \xE9t\xE9 automatiquement assign\xE9 (voir l'option nick) - (false par d\xE9faut) - max_nick_len - C'est la longeur maximale que peut avoir un pseudonyme - (15de caract\xE8res par d\xE9faut) - max_text_len - C'est la longeur maximale que peut avoir un message. - ( 250 caract\xE8res par d\xE9faut) - refresh_delay - Ceci est le temps \xE0 attendre entre chaque rafrechissements. Un - rafrechissement correspond \xE0 une requete HTTP demandant au serveur - si il y a quelque chose de nouveau \xE0 afficher ou pas. S'il n'y a - rien de nouveau alors la r\xE9ponse HTTP est vide. - ( 5000ms = 5s par d\xE9faut) - timeout - Ceci est le temps d'inactivit\xE9 \xE0 attendre avant de d\xE9connecter un - utilisateur (en millisecondes). - ( 20000ms = 20s par d\xE9faut) - max_msg - Ceci est la taille de l'historique, c'est \xE0 dire le nombre de - messages gard\xE9s en m\xE9moire. Quand un utilisateur se connect, il voit - automatiquement les messages de l'historique. Le nombre de messages - qu'il voit est d\xE9finit par ce param\xE8tre - (20 lignes par d\xE9faut) - connect_at_startup - Mettre cette option \xE0 false obligera les utilisateurs \xE0 cliquer sur - l'icone de connexion pour tchater. - (true par d\xE9faut, signifie que les utilisateurs sont automatiquement - connect\xE9s lorsque la page du chat est ouverte) - start_minimized - Mettre cette option \xE0 true minimizera le chat au premier chargement - de la page. - (false par d\xE9faut) - height - Hauteur de la zone de chat - (440px par d\xE9faut) - width - Largeur de la zone de chat - ("" par d\xE9faut, signifie que la valeur est assign\xE9es dans les CSS) - shownotice - Trois valeurs sont possibles : 0 pour ne rien afficher (ni les - notices de connexion/deconnexion, ni les changements de pseudo), 1 - pour afficher seulement les changements de pseudo, 2 pour afficher - les changements de pseudo et les connexions/deconnexions. - (2 par d\xE9faut) - nickmarker - Mettre cette option \xE0 false d\xE9sactivera la colorisation des - pseudonymes. - (true par d\xE9faut) - clock - Mettre cette option \xE0 false d\xE9sactivera l'affichage de la date et de - l'heure. - (true par d\xE9faut) - openlinknewwindow - Mettre cette option \xE0 true permettra d'ouvrire les liens des - convertations dans une nouvelle fen\xEAtre. Techniquement cela rajoute - l'attribut target="_blank" dans la balise du lien. - (true par d\xE9faut) - showwhosonline - Permet de cacher/montrer la liste des utilisateurs connect\xE9s lors du - premier affichage du chat. - Utilisez btn_sh_whosonline pour d\xE9sactiver compl\xE8tement la - possibilit\xE9 de voir la liste des pseudonymes. - (true par d\xE9faut) - showsmileys - Permet de cacher/montrer la liste des smileys lors du premier - affichage du chat. - Utilisez btn_sh_smileys pour d\xE9sactiver compl\xE8tement la possibilit\xE9 - de voir la liste des smileys. - (true par d\xE9faut) - btn_sh_whosonline - Permet de cacher ou montrer le bouton showwhosonline (celui qui - permet de cacher/montrer la liste des pseudonymes) - (true par d\xE9faut) - btn_sh_smileys - Permet de cacher ou montrer le bouton showsmileys (celui qui permet - de cacher/montrer la liste des smileys) - (true par d\xE9faut) - themeurl - Permet de sp\xE9cifier l'url \xE0 utiliser pour acceder aux themes (tr\xE8s - utile pour la r\xE9\xE9criture d'url) - (ce param\xE8tre est automatiquement calcul\xE9 en fonction de themepath - themepath - Le chemin vers les themes. Les sous r\xE9pertoires sont les diff\xE9rents - thems disponibles. - (dirname(__FILE__)."/../themes" par d\xE9faut) - theme - Ce peram\xE8tre permet de sp\xE9cifier quelle theme utiliser. La liste des - themes possible sont les nom des sous r\xE9pertoires de themepath. - ("default" par d\xE9faut) - language - Permet d'afficher le chat dans une langue donn\xE9e. Les valeurs - possibles sont les nom des sous r\xE9pertoires de i18n. - (par d\xE9faut la langue est celle du serveur qui h\xE9berge le chat) - output_encoding - Permet de sp\xE9cifier l'encodage \xE0 utiliser pour afficher les labels. - Concretement ce param\xE8tre doit correspondre \xE0 l'encodage de la page - Web contenant le chat. - (par d\xE9faut UTF-8, c'est \xE0 dire aucun transcodage car les messages - sont stoqu\xE9s en UTF-8 par d\xE9faut) - container_type - Permet de sp\xE9ficier le conteneur \xE0 utiliser. Pour le moment, seul le - conteneur File (syst\xE8me de fichier) est disponible mais dans le - future de nombreux conteneurs existerons surrement (mysql, irc, msn, - jabber...). - ("File" par d\xE9faut) - server_script_path et server_script_url - Ces param\xE8tres permettent de sp\xE9cifier un script externe qui sera - charg\xE9 des communication client/serveur du chat. Ce param\xE8tre est - tr\xE8s utile lorsque le script du chat (client) consomme beaucoup de - ressources (voyez la demo3 pour un exemple concret). Le premier - param\xE8tre sp\xE9cifie l'endroit du fichier lui m\xEAme, le second - param\xE8tre indique l'url o\xF9 est situ\xE9 le fichier (utile pour la - r\xE9\xE9criture d'url) - (par d\xE9faut on utilise le m\xEAme scripte que le script client pour les - communications) - client_script_path et client_script_url - Ces param\xE8tres sont utilis\xE9s pour sp\xE9cifier le chemin du script qui - va afficher le chat (script client). Ces options peuvent \xEAtre utile - lorsque la configuration du serveur est peu commune. Le premier - param\xE8tre sp\xE9cifie l'endroit du fichier lui m\xEAme, le second - param\xE8tre indique l'url o\xF9 est situ\xE9 le fichier (utile pour la - r\xE9\xE9criture d'url) - (par d\xE9faut pfc va essayer d'auto-detecter le script client en - fonction des variables globales du serveur) - useie7 - Mettre ce param\xE8tre \xE0 false d\xE9sactivera l'ajout des scripts IE7[24] - permettant un meilleur affichage dans Internet Explorer. - (true par d\xE9faut) - ie7path - Sp\xE9cifie le r\xE9pertoire vers la librairie IE7. Ce param\xE8tre est utile - si vous avez d\xE9j\xE0 install\xE9 une librairie smarty et que vous voulez - \xE9conomiser des octets sur votre serveur. - (dirname(__FILE__)."/../lib/IE7_0_9" par d\xE9faut) - jspath - Sp\xE9cifie le r\xE9pertoire vers les librairies javascript (md5, cookie - ...). - (dirname(__FILE__)."/../lib/javascript" par d\xE9faut) - usecsstidy - Mettre ce param\xE8tre \xE0 false d\xE9sactivera l'utilisation de la - librairie CSSTidy utilis\xE9e pour optimiser (en taille) la g\xE9n\xE9ration - des CSS. - (false par d\xE9faut car sur certains serveur la librarie CSSTidy pose - des probl\xE8mes) - csstidypath - Sp\xE9cifie le r\xE9pertoire vers la librairie CSS Tidy[25]. Ce param\xE8tre - est utile si vous avez d\xE9j\xE0 install\xE9 une librairie csstidy et que - vous voulez \xE9conomiser des octets sur votre serveur. - (dirname(__FILE__)."/../lib/csstidy-1.1" par d\xE9faut) - xajaxpath - Sp\xE9cifie le r\xE9pertoire vers la librairie xajax[26]. Ce param\xE8tre est - utile si vous avez d\xE9j\xE0 install\xE9 une librairie xajax et que vous - voulez \xE9conomiser des octets sur votre serveur. - (dirname(__FILE__)."/../lib/xajax_0.2_stable" par d\xE9faut) - data_private_path - Ce r\xE9pertoire est utilis\xE9 pour stoqu\xE9 les donn\xE9es du chat ainsi que - les templates compil\xE9s de smarty. Astuce: vous pouvez optimisez les - performances cot\xE9 serveur en sp\xE9cifiant un r\xE9pertoire en m\xE9moire - vive (RAM disk, tmpfs), voyez cette section dans la FAQ[27]. - (dirname(__FILE__)."/../data/private" par d\xE9faut) - data_public_path et data_public_url - Ce r\xE9pertoire doit \xEAtre imp\xE9rativement accessible par votre serveur - Web. Les scripts IE7 et xajax necessaires au chat y seront stock\xE9s. - Le premier param\xE8tre indique le r\xE9pertoire absolue au niveau syst\xE8me - de fichier, et le second indique l'url pour y acceder depuis le - navigateur (utile pour la r\xE9\xE9critude d'url) - (dirname(__FILE__)."/../data/public" par d\xE9faut, data_public_url lui - est calcul\xE9 automatiquement) - debug - Cette option est tr\xE8s utile pour les d\xE9veloppeurs. La mettre \xE0 true - va activer les messages de log et la console de debug. - (false par d\xE9faut) - debugxajax - Cette option est tr\xE8s utile pour d\xE9couvrire les bug cach\xE9s (warning - php lors d'une requete xajax par exemple) . Mettre cette option \xE0 - true va activer les popup javascript de xajax pour tracer la - communication client/serveur. - (false par d\xE9faut) - prefix - Ce prefix est utilis\xE9 pour chaques fonctions javascript, chaque id - CSS et chaques classes CSS de fa\xE7on \xE0 \xE9viter les recouvrements de - variables entre phpfreechat et votre site web. - ("phpfreechat_" par d\xE9faut) - - - - \xA92006 phpFreeChat - - - --------------------------------------------------------------- -List of References - -Document's URL: http://www.phpfreechat.net/install.fr.html -[23] faq.fr.html#multiple-channels -[24] http://dean.edwards.name/IE7/ -[25] http://csstidy.sourceforge.net/index.php -[26] http://www.xajaxproject.org/ -[27] faq.fr.html#tmpfs Deleted: trunk/README.en =================================================================== --- trunk/README.en 2006-09-02 20:38:40 UTC (rev 724) +++ trunk/README.en 2006-09-02 20:42:09 UTC (rev 725) @@ -1,64 +0,0 @@ -phpFreeChat, a free, simple, fast and customizable chat server - - Simple - You only have to copy/paste 3 lines of code[21] to have a nice - working chat. - No need to configure a database (Mysql), messages and nicknames are - stored in files. - No problems with firewalls, this script is based on HTTP so you only - need a web browser and an internet connection. (everyone can easily - chat!) - No problems with none-latin characteres ! Are you Russian, Japanese, - Turk, Chinese, or Arabic? Whatever language you speak, phpfreechat - will nicely display your characters because it uses XML with UTF8 to - encode characters. - Fast - AJAX technology is used to smoothly refresh (no flicker) and display - the chat and nickname zone. - Messages and nicknames are stored into a simple filesystem, so that - server resources are saved as much as possible. - Bandwidth is preserved because the server never transmits the same - data twice, only new messages are transmitted. - Customizable - You can write your own customized CSS stylesheets, to completely - change the appearance[22] of your chat. - All chat functionalities are customizable. For example, you can - change the messages refresh time, you can ban users for changing - their usernames, etc. - The plugin system[23] allows you to write your own storage routines. - For example, you can write a plugin to store the conversations into - your database. - Opensource - phpFreeChat is an opensource (LGPL) program, so that you can freely - use it and modify it. - I just ask, by gratitude, to keep the linkback logo on the pages of - your chat. - - All phpFreeChat commands are inspired by the irc[24] protocol, and its - interface is inspired by mIRC[25] and XChat[26], so that users won't be - disoriented. - - Techonologies used by phpFreeChat are: - - * PHP[27] : on the server side : conversations are simply stored in - filesystems. - * XAJAX[28] : for the asynchronous communication between the client - and the server - - (phpFreeChat does NOT require MySQL, or any SQL database) - - \xA92006 phpFreeChat - - --------------------------------------------------------------- -List of References - -Document's URL: http://www.phpfreechat.net/overview.en.html -[22] customize.en.html#cust-css -[23] customize.en.html#container-plug -[24] http://www.irc.org -[25] http://www.mirc.com/ -[26] http://www.xchat.org/ -[27] http://www.php.net/ -[28] http://www.xajaxproject.org/ - Deleted: trunk/README.fr =================================================================== --- trunk/README.fr 2006-09-02 20:38:40 UTC (rev 724) +++ trunk/README.fr 2006-09-02 20:42:09 UTC (rev 725) @@ -1,67 +0,0 @@ - -phpFreeChat un serveur de chat libre, simple, rapide et param\xE9trable - - Simple - Vous avez seulement 3 lignes de php \xE0 copier/coller[21] dans la page - de votre choix pour obtenir un chat fonctionnel. - En effet, pas besoin de param\xE9trer une base de donn\xE9e Mysql, les - conversations sont stock\xE9es simplement dans des fichiers. - Le chat fontionnera chez tout le monde car il est bas\xE9 sur HTTP, il - vous suffit donc d'avoir un navigateur Web connect\xE9 \xE0 internet pour - pouvoir chatter. - Tous les jeux de caract\xE8res sont support\xE9s ! Que vous soyez Russe, - Japonais, Turque, Chinois, ou Arabe, tous les caract\xE8res - s'afficheront car phpfreechat utilise XML coupl\xE9 \xE0 UTF8 pour encoder - les caract\xE8res. - Rapide - La technologie AJAX est utilis\xE9e pour afficher p\xE9riodiquement et - sans effets de clignotement les nouveaux messages et les nouvelles - personnes connect\xE9es. - Les conversations sont stock\xE9es dans des fichiers, les ressources du - serveur sont donc \xE9conomis\xE9es au maximum. - La bande passante est \xE9conomis\xE9e car le serveur ne transmettra - jamais deux fois les m\xEAmes informations : seulement les nouveaux - messages sont transmis. - Param\xE9trable - Vous pouvez \xE9crire vos feuilles de style (CSS) personnalis\xE9es pour - changer compl\xE8tement l'apparence[22] de votre chat. - Toutes les fonctionnalit\xE9s du chat ont \xE9t\xE9 rendues param\xE9trables. - Par exemple, vous pouvez changer le temps de mise \xE0 jour des - messages, vous pouvez interdire aux utilisateurs de changer leur - pseudo... - Vous pouvez \xE9galement, gr\xE2ce au syst\xE8me de plugin[23], \xE9crire vos - propres routines de stockage si vous pr\xE9f\xE9rez stocker les - conversations dans votre base de donn\xE9es. - Libre - phpFreeChat est d\xE9velopp\xE9 en opensource (LGPL), vous pouvez donc - librement utiliser le programme et le modifier. - Je demande juste, par gratitude, de ne pas enlever la signature logo - sur les pages de votre chat. - - Toutes les commandes de phpFreeChat sont inspir\xE9es du protocole irc[24], - et son interface est inspir\xE9e de mIRC[25] et XChat[26], vos utilisateurs - ne seront donc pas d\xE9pays\xE9s. - - Les technologies utilis\xE9es par phpFreeChat sont : - - * php[27] : pour le cot\xE9 serveur, les conversations sont simplement - enregistr\xE9es dans des fichiers - * xajax[28] : pour la communication asynchrone entre le client et le - serveur - - (phpFreeChat n'utilise PAS mysql) - - \xA92006 phpFreeChat - - --------------------------------------------------------------- -List of References - -Document's URL: http://www.phpfreechat.net/overview.fr.html -[22] customize.fr.html#custo-css -[23] customize.fr.html#container-plug -[24] http://www.irc.org -[25] http://www.mirc.com/ -[26] http://www.xchat.org/ -[27] http://www.php.net/ -[28] http://www.xajaxproject.org/ Modified: trunk/misc/tarSource =================================================================== --- trunk/misc/tarSource 2006-09-02 20:38:40 UTC (rev 724) +++ trunk/misc/tarSource 2006-09-02 20:42:09 UTC (rev 725) @@ -8,6 +8,20 @@ rm -rf ./$NAME svn export .. ./$NAME rm -rf ./$NAME/contrib +echo "-> downloading documentation" +wget http://www.phpfreechat.net/pages/fr/install.html -q -O ./$NAME/INSTALL.fr.html +wget http://www.phpfreechat.net/pages/en/install.html -q -O ./$NAME/INSTALL.en.html +wget http://www.phpfreechat.net/pages/fr/faq.html -q -O ./$NAME/FAQ.fr.html +wget http://www.phpfreechat.net/pages/en/faq.html -q -O ./$NAME/FAQ.en.html +wget http://www.phpfreechat.net/pages/fr/overview.html -q -O ./$NAME/OVERVIEW.fr.html +wget http://www.phpfreechat.net/pages/en/overview.html -q -O ./$NAME/OVERVIEW.en.html +wget http://www.phpfreechat.net/pages/ar/overview.html -q -O ./$NAME/OVERVIEW.ar.html +wget http://www.phpfreechat.net/pages/es/overview.html -q -O ./$NAME/OVERVIEW.es.html +wget http://www.phpfreechat.net/pages/zh/overview.html -q -O ./$NAME/OVERVIEW.zh.html +wget http://www.phpfreechat.net/pages/fr/customize.html -q -O ./$NAME/CUSTOMIZE.fr.html +wget http://www.phpfreechat.net/pages/en/customize.html -q -O ./$NAME/CUSTOMIZE.en.html +wget http://www.phpfreechat.net/pages/fr/changelog.html -q -O ./$NAME/CHANGELOG.fr.html +wget http://www.phpfreechat.net/pages/en/changelog.html -q -O ./$NAME/CHANGELOG.en.html echo "-> creating checkmd5.php file" ./checkmd5 ./$NAME ./$NAME/checkmd5.php Modified: trunk/src/pfcglobalconfig.class.php =================================================================== --- trunk/src/pfcglobalconfig.class.php 2006-09-02 20:38:40 UTC (rev 724) +++ trunk/src/pfcglobalconfig.class.php 2006-09-02 20:42:09 UTC (rev 725) @@ -391,24 +391,25 @@ $this->errors[] = _pfc("'%s' parameter is not valid. Available values are : '%s'", "language", implode(", ", $lg_list)); // install the proxy file - $proxyfile = $this->_getProxyFile(); - $allowedpath_string = ""; - $allowedpath_string .= "\$allowedpath[] = '".realpath(dirname(__FILE__)."/../lib")."';\n"; - $allowedpath_string .= "\$allowedpath[] = '".realpath(dirname(__FILE__)."/../src/client")."';\n"; - $allowedpath_string .= "\$allowedpath[] = '".realpath($this->themepath_default)."/..';\n"; - $allowedpath_string .= "\$allowedpath[] = '".realpath($this->themepath_default)."';\n"; - $allowedpath_string .= "\$allowedpath[] = '".realpath($this->themepath)."/..';\n"; - $allowedpath_string .= "\$allowedpath[] = '".realpath($this->themepath)."';\n"; - $proxycontent = file_get_contents(dirname(__FILE__)."/client/proxy.php.tpl"); - $proxycontent = str_replace("//%allowedpath%", $allowedpath_string, $proxycontent); - if (!file_exists(dirname($proxyfile))) - mkdir(dirname($proxyfile)); - if (file_exists($proxyfile) && - !is_writable($proxyfile)) - $this->errors[] = _pfc("'%s' must be writable", $proxyfile); - else + if (count($this->errors) == 0) { - file_put_contents($proxyfile, $proxycontent); + $proxyfile = $this->_getProxyFile(); + $allowedpath_string = ""; + $allowedpath_string .= "\$allowedpath[] = '".realpath(dirname(__FILE__)."/../lib")."';\n"; + $allowedpath_string .= "\$allowedpath[] = '".realpath(dirname(__FILE__)."/../src/client")."';\n"; + $allowedpath_string .= "\$allowedpath[] = '".realpath($this->themepath_default)."/..';\n"; + $allowedpath_string .= "\$allowedpath[] = '".realpath($this->themepath_default)."';\n"; + $allowedpath_string .= "\$allowedpath[] = '".realpath($this->themepath)."/..';\n"; + $allowedpath_string .= "\$allowedpath[] = '".realpath($this->themepath)."';\n"; + $proxycontent = file_get_contents(dirname(__FILE__)."/client/proxy.php.tpl"); + $proxycontent = str_replace("//%allowedpath%", $allowedpath_string, $proxycontent); + if (!file_exists(dirname($proxyfile))) + @mkdir(dirname($proxyfile)); + if (file_exists($proxyfile) && + !is_writable($proxyfile)) + $this->errors[] = _pfc("'%s' must be writable", $proxyfile); + else + @file_put_contents($proxyfile, $proxycontent); } // load smileys from file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-02 20:38:51
|
Revision: 724 http://svn.sourceforge.net/phpfreechat/?rev=724&view=rev Author: kerphi Date: 2006-09-02 13:38:40 -0700 (Sat, 02 Sep 2006) Log Message: ----------- Bug fix: if preg_* module is not compiled with utf8 support, a warning occurs Modified Paths: -------------- trunk/src/phpfreechat.class.php Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-09-02 20:14:57 UTC (rev 723) +++ trunk/src/phpfreechat.class.php 2006-09-02 20:38:40 UTC (rev 724) @@ -228,7 +228,7 @@ $c =& pfcGlobalConfig::Instance(); //$nickname = str_replace("\\", "", $nickname); // '\' is a forbidden charactere for nicknames $nickname = trim($nickname); - $nickname = utf8_substr($nickname, 0, $c->max_nick_len); + $nickname = @utf8_substr($nickname, 0, $c->max_nick_len); return $nickname; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-02 20:15:12
|
Revision: 723 http://svn.sourceforge.net/phpfreechat/?rev=723&view=rev Author: kerphi Date: 2006-09-02 13:14:57 -0700 (Sat, 02 Sep 2006) Log Message: ----------- The proxy log data must be saved by default in the private directory Modified Paths: -------------- trunk/src/pfctools.php trunk/src/proxys/log.class.php Modified: trunk/src/pfctools.php =================================================================== --- trunk/src/pfctools.php 2006-09-01 15:11:27 UTC (rev 722) +++ trunk/src/pfctools.php 2006-09-02 20:14:57 UTC (rev 723) @@ -112,7 +112,7 @@ } -function mkdir_r($path, $modedir = 0700) +function mkdir_r($path, $modedir = 0775) { // This function creates the specified directory using mkdir(). Note // that the recursive feature on mkdir() is broken with PHP 5.0.4 for @@ -146,7 +146,7 @@ * @param string $dest Destination path * @return bool Returns TRUE on success, FALSE on failure */ -function copy_r($source, $dest, $modedir = 0755, $modefile = 0644) +function copy_r($source, $dest, $modedir = 0775, $modefile = 0664) { // Simple copy for a file if (is_file($source)) { Modified: trunk/src/proxys/log.class.php =================================================================== --- trunk/src/proxys/log.class.php 2006-09-01 15:11:27 UTC (rev 722) +++ trunk/src/proxys/log.class.php 2006-09-02 20:14:57 UTC (rev 723) @@ -43,23 +43,31 @@ $c =& $this->c; $u =& $this->u; - $logpath = ($c->proxys_cfg[$this->proxyname]["path"] == "" ? $c->data_public_path : - $c->proxys_cfg[$this->proxyname]["path"]); - $logfile = $logpath."/".$c->getId()."/chat.log"; - if (is_writable($logpath)) + $logpath = ($c->proxys_cfg[$this->proxyname]["path"] == "" ? $c->data_private_path."/logs" : + $c->proxys_cfg[$this->proxyname]["path"]); + $logpath .= "/".$c->getId(); + + if (!file_exists($logpath)) @mkdir_r($logpath); + if (file_exists($logpath) && is_writable($logpath)) { + $logfile = $logpath."/chat.log"; $f_exists = file_exists($logfile); if (($f_exists && is_writable($logpath)) || !$f_exists) { $fp = fopen($logfile, $f_exists ? 'a' : 'w'); // @todo write logs in a cleaner structured language (xml, html ... ?) - fwrite($fp, $recipient."\t".$sender."\t".$param."\n"); + $log = $recipient."\t"; + $log .= date("d/m/Y")."\t"; + $log .= date("H:i:s")."\t"; + $log .= $sender."\t"; + $log .= $param."\n"; + fwrite($fp, $log); fclose($fp); } } } - + // forward the command to the next proxy or to the final command $this->next->run($xml_reponse, $p); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-09-01 15:11:52
|
Revision: 722 http://svn.sourceforge.net/phpfreechat/?rev=722&view=rev Author: kerphi Date: 2006-09-01 08:11:27 -0700 (Fri, 01 Sep 2006) Log Message: ----------- correct the proxy parameters Modified Paths: -------------- trunk/contrib/pfcInstaller2/step2.php Modified: trunk/contrib/pfcInstaller2/step2.php =================================================================== --- trunk/contrib/pfcInstaller2/step2.php 2006-08-30 21:05:51 UTC (rev 721) +++ trunk/contrib/pfcInstaller2/step2.php 2006-09-01 15:11:27 UTC (rev 722) @@ -21,8 +21,8 @@ @unlink($dstpath."/".$archivename); $param = array(); - if (isset($_GET["host"])) $http["proxy_host"] = $_GET["host"]; - if (isset($_GET["port"])) $http["proxy_port"] = $_GET["port"]; + if (isset($_GET["host"])) $param["proxy_host"] = $_GET["host"]; + if (isset($_GET["port"])) $param["proxy_port"] = $_GET["port"]; require_once "HTTP/Request.php"; $nextmirror = false; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-08-30 21:06:14
|
Revision: 721 http://svn.sourceforge.net/phpfreechat/?rev=721&view=rev Author: kerphi Date: 2006-08-30 14:05:51 -0700 (Wed, 30 Aug 2006) Log Message: ----------- rename archive to archivename because of windows problem Modified Paths: -------------- trunk/contrib/pfcInstaller2/config.php trunk/misc/tarSource Added Paths: ----------- trunk/contrib/pfcInstaller2/archivename Removed Paths: ------------- trunk/contrib/pfcInstaller2/archive Deleted: trunk/contrib/pfcInstaller2/archive =================================================================== --- trunk/contrib/pfcInstaller2/archive 2006-08-29 21:18:06 UTC (rev 720) +++ trunk/contrib/pfcInstaller2/archive 2006-08-30 21:05:51 UTC (rev 721) @@ -1 +0,0 @@ -phpfreechat-1.0-beta5.tar.gz Copied: trunk/contrib/pfcInstaller2/archivename (from rev 720, trunk/contrib/pfcInstaller2/archive) =================================================================== --- trunk/contrib/pfcInstaller2/archivename (rev 0) +++ trunk/contrib/pfcInstaller2/archivename 2006-08-30 21:05:51 UTC (rev 721) @@ -0,0 +1 @@ +phpfreechat-1.0-beta5.tar.gz Modified: trunk/contrib/pfcInstaller2/config.php =================================================================== --- trunk/contrib/pfcInstaller2/config.php 2006-08-29 21:18:06 UTC (rev 720) +++ trunk/contrib/pfcInstaller2/config.php 2006-08-30 21:05:51 UTC (rev 721) @@ -3,7 +3,7 @@ require_once dirname(__FILE__).'/file_get_contents.php'; require_once dirname(__FILE__).'/file_put_contents.php'; -$archivename = trim(file_get_contents(dirname(__FILE__)."/archive")); +$archivename = trim(file_get_contents(dirname(__FILE__)."/archivename")); $archivename2 = str_replace(".tar.gz","",str_replace(".zip","",$archivename)); $mirrors = file(dirname(__FILE__)."/mirrors"); $dstpath = dirname(__FILE__)."/data"; Modified: trunk/misc/tarSource =================================================================== --- trunk/misc/tarSource 2006-08-29 21:18:06 UTC (rev 720) +++ trunk/misc/tarSource 2006-08-30 21:05:51 UTC (rev 721) @@ -33,7 +33,7 @@ rm -rf ./$PFCSETUPNAME/pear.sh rm -rf ./$PFCSETUPNAME/pearrc rm -rf ./$PFCSETUPNAME/OS -echo "$NAME.tar.gz" > $PFCSETUPNAME/archive +echo "$NAME.tar.gz" > $PFCSETUPNAME/archivename echo `pwd` >> $PFCSETUPNAME/mirrors tar czfp $PFCSETUPNAME.tar.gz ./$PFCSETUPNAME echo "-> creating $PFCSETUPNAME.zip" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-08-29 21:18:20
|
Revision: 720 Author: kerphi Date: 2006-08-29 14:18:06 -0700 (Tue, 29 Aug 2006) ViewCVS: http://svn.sourceforge.net/phpfreechat/?rev=720&view=rev Log Message: ----------- add a script to upload release on sourceforge Modified Paths: -------------- trunk/misc/tarSource Added Paths: ----------- trunk/misc/sendSource Added: trunk/misc/sendSource =================================================================== --- trunk/misc/sendSource (rev 0) +++ trunk/misc/sendSource 2006-08-29 21:18:06 UTC (rev 720) @@ -0,0 +1,11 @@ +#!/bin/sh + +NAME_TGZ=phpfreechat-`cat ../version`.tar.gz +NAME_ZIP=phpfreechat-`cat ../version`.zip +PFCSETUP_TGZ=pfcsetup-`cat ../version`.tar.gz +PFCSETUP_ZIP=pfcsetup-`cat ../version`.zip + +lftp -c "mput -O ftp://upload.sourceforge.net/incoming/ $NAME_TGZ" +lftp -c "mput -O ftp://upload.sourceforge.net/incoming/ $NAME_ZIP" +lftp -c "mput -O ftp://upload.sourceforge.net/incoming/ $PFCSETUP_TGZ" +lftp -c "mput -O ftp://upload.sourceforge.net/incoming/ $PFCSETUP_ZIP" Property changes on: trunk/misc/sendSource ___________________________________________________________________ Name: svn:executable + * Modified: trunk/misc/tarSource =================================================================== --- trunk/misc/tarSource 2006-08-29 21:06:57 UTC (rev 719) +++ trunk/misc/tarSource 2006-08-29 21:18:06 UTC (rev 720) @@ -12,13 +12,12 @@ echo "-> creating checkmd5.php file" ./checkmd5 ./$NAME ./$NAME/checkmd5.php -echo "-> creating .tar.gz" +echo "-> creating $NAME.tar.gz" tar czfp $NAME.tar.gz ./$NAME - -echo "-> creating .zip" +echo "-> creating $NAME.zip" zip -Tq9r $NAME.zip ./$NAME -echo "-> creating $PFCSETUPNAME" +echo "-> creating $PFCSETUPNAME.tar.gz" rm -rf ./$PFCSETUPNAME svn export ../contrib/pfcInstaller2 $PFCSETUPNAME rm -rf ./$PFCSETUPNAME/.registry @@ -37,6 +36,8 @@ echo "$NAME.tar.gz" > $PFCSETUPNAME/archive echo `pwd` >> $PFCSETUPNAME/mirrors tar czfp $PFCSETUPNAME.tar.gz ./$PFCSETUPNAME +echo "-> creating $PFCSETUPNAME.zip" +zip -Tq9r $PFCSETUPNAME.zip ./$PFCSETUPNAME echo "-> removing temporary files" rm -rf ./$NAME This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-08-29 21:07:07
|
Revision: 719 Author: kerphi Date: 2006-08-29 14:06:57 -0700 (Tue, 29 Aug 2006) ViewCVS: http://svn.sourceforge.net/phpfreechat/?rev=719&view=rev Log Message: ----------- rename the installer Modified Paths: -------------- trunk/contrib/pfcInstaller2/step1.php trunk/contrib/pfcInstaller2/step2.php Modified: trunk/contrib/pfcInstaller2/step1.php =================================================================== --- trunk/contrib/pfcInstaller2/step1.php 2006-08-29 21:04:36 UTC (rev 718) +++ trunk/contrib/pfcInstaller2/step1.php 2006-08-29 21:06:57 UTC (rev 719) @@ -3,10 +3,10 @@ <html> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> - <title>pfcInstaller - Step 1 / 2</title> + <title>pfcSetup - Step 1 / 2</title> </head> <body> -<h1>pfcInstaller - Step 1 / 2</h1> +<h1>pfcSetup - Step 1 / 2</h1> <?php if (!$isinstalled) { ?> <table width="80%"> <tr> Modified: trunk/contrib/pfcInstaller2/step2.php =================================================================== --- trunk/contrib/pfcInstaller2/step2.php 2006-08-29 21:04:36 UTC (rev 718) +++ trunk/contrib/pfcInstaller2/step2.php 2006-08-29 21:06:57 UTC (rev 719) @@ -3,10 +3,10 @@ <html> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> - <title>pfcInstaller - Step 2/2</title> + <title>pfcSetup - Step 2/2</title> </head> <body> -<h1>pfcInstaller - Step 2/2</h1> +<h1>pfcSetup - Step 2/2</h1> <?php if (!$isinstalled) { ?> <p>Installation de <?php echo $archivename; ?> </p> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-08-29 21:04:43
|
Revision: 718 Author: kerphi Date: 2006-08-29 14:04:36 -0700 (Tue, 29 Aug 2006) ViewCVS: http://svn.sourceforge.net/phpfreechat/?rev=718&view=rev Log Message: ----------- fix demo43 Modified Paths: -------------- trunk/demo/demo43_change_the_nicknames_colors.php trunk/demo/index.php Removed Paths: ------------- trunk/demo/demo43_change_the_nicknames_colors/ Modified: trunk/demo/demo43_change_the_nicknames_colors.php =================================================================== --- trunk/demo/demo43_change_the_nicknames_colors.php 2006-08-29 21:01:10 UTC (rev 717) +++ trunk/demo/demo43_change_the_nicknames_colors.php 2006-08-29 21:04:36 UTC (rev 718) @@ -5,8 +5,7 @@ $params["serverid"] = md5(__FILE__); // calculate a unique id for this chat $params["nick"] = "guest".rand(1,10); // setup the intitial nickname $params["title"] = "A chat with a customized nickname color list"; -$params["themepath"] = dirname(__FILE__)."/demo43_change_the_nicknames_colors"; -$params["theme"] = "mytheme"; +$params["nickname_colorlist"] = array('#FF0000','#00FF00','#0000FF'); $chat = new phpFreeChat( $params ); ?> Modified: trunk/demo/index.php =================================================================== --- trunk/demo/index.php 2006-08-29 21:01:10 UTC (rev 717) +++ trunk/demo/index.php 2006-08-29 21:04:36 UTC (rev 718) @@ -73,7 +73,7 @@ <li><a href="demo32_show_last_messages-showlastmsg.php">demo32 - demo which show how to get the last posted messages (showlastmsg script)</a></li> <li><a href="demo35_shared_memory.php">demo35 - demo which show how to use the shared memory container</a> (not yet working)</li> - <li><a href="demo43_change_the_nicknames_colors.php">demo43 - demo which show how to change the nicknames automatic colors</a> (not yet working)</li> + <li><a href="demo43_change_the_nicknames_colors.php">demo43 - demo which show how to change the nicknames automatic colors</a></li> </ul> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |