phpfreechat-svn Mailing List for phpFreeChat (Page 16)
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-12-19 22:35:24
|
Revision: 904 http://svn.sourceforge.net/phpfreechat/?rev=904&view=rev Author: kerphi Date: 2006-12-19 14:35:09 -0800 (Tue, 19 Dec 2006) Log Message: ----------- Container optimization: add a memory cache (work in progress) Modified Paths: -------------- trunk/src/pfccontainer.class.php Modified: trunk/src/pfccontainer.class.php =================================================================== --- trunk/src/pfccontainer.class.php 2006-12-19 22:32:45 UTC (rev 903) +++ trunk/src/pfccontainer.class.php 2006-12-19 22:35:09 UTC (rev 904) @@ -289,7 +289,7 @@ { if ($chan == NULL) $chan = 'SERVER'; - $ret = $this->getMeta("channelid-to-nickid", $this->encode($chan)); + $ret = $this->getMeta("channelid-to-nickid", $this->encode($chan)); for($i = 0; $i<count($ret['timestamp']); $i++) { if ($ret['value'][$i] == $nickid) return $i; @@ -493,17 +493,22 @@ { $ret = $this->_container->setMeta($group, $subgroup, $leaf, $leafvalue); - echo "setMeta($group, $subgroup, $leaf, $leafvalue)\n"; - //print_r($ret); + // echo "setMeta($group, $subgroup, $leaf, $leafvalue)\n"; - - // @todo creer la bonne hierarchie du cache - - //$this->_cache['group'][$group] = array_merge($this->_cache['group'][$group],array($subgroup)); - //$this->_cache[$group][$subgroup][$leaf] = $leafvalue; - - //$this->_cache['subgroup'][$group][$subgroup] = $ret; - //$this->_cache['leaf'][$group][$subgroup][$leaf] = ($withleafvalue ? ; + if (isset($this->_cache[$group]['value']) && + !in_array($subgroup, $this->_cache[$group]['value'])) + { + $this->_cache[$group]['value'][] = $subgroup; + $this->_cache[$group]['timestamp'][] = time(); + } + if (isset($this->_cache[$group]['childs'][$subgroup]['value']) && + !in_array($leaf, $this->_cache[$group]['childs'][$subgroup]['value'])) + { + $this->_cache[$group]['childs'][$subgroup]['value'][] = $leaf; + $this->_cache[$group]['childs'][$subgroup]['timestamp'][] = time(); + } + $this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]['value'] = array($leafvalue); + $this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]['timestamp'] = array(time()); return $ret; } @@ -519,52 +524,58 @@ */ function getMeta($group, $subgroup = null, $leaf = null, $withleafvalue = false) { - echo "getMeta($group, $subgroup, $leaf, $withleafvalue)\n"; + $ret = array('timestamp' => array(), + 'value' => array()); + // check in the cache - $ret = array('timestamp' => array(), - 'value' => array()); + $incache = false; if ($subgroup == null && isset($this->_cache[$group]['value'])) { - $ret['timestamp'] = $this->_cache[$group]['timestamp']; - $ret['value'] = $this->_cache[$group]['value']; - echo "getMeta->incache\n"; - return $ret; + $incache = true; + $ret = $this->_cache[$group]; } else if ($leaf == null && - isset($this->_cache[$group][$subgroup]['value'])) + isset($this->_cache[$group]['childs'][$subgroup]['value'])) { - $ret['timestamp'] = $this->_cache[$group][$subgroup]['timestamp']; - $ret['value'] = $this->_cache[$group][$subgroup]['value']; - echo "getMeta->incache\n"; - return $ret; + $incache = true; + $ret = $this->_cache[$group]['childs'][$subgroup]; } else { if ($withleafvalue) { - if (isset($this->_cache[$group][$subgroup][$leaf]['value'])) + if (isset($this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]['value'])) { - echo "getMeta->incache\n"; - return $this->_cache[$group][$subgroup][$leaf]; + $incache = true; + $ret = $this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]; } } else { - if (isset($this->_cache[$group][$subgroup][$leaf]['timestamp'])) + if (isset($this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]['timestamp'])) { - echo "getMeta->incache\n"; - return $this->_cache[$group][$subgroup][$leaf]; + $incache = true; + $ret = $this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]; } } } - echo "getMeta->notincache\n"; + // echo "getMeta($group, $subgroup, $leaf, $withleafvalue)".($incache?"incache":"notincache")."\n"; + + if ($incache) + { + $ret = array('timestamp' => $ret['timestamp'], + 'value' => $ret['value']); + return $ret; + } + // get the fresh data $ret = $this->_container->getMeta($group, $subgroup, $leaf, $withleafvalue); + // store in the cache if ($subgroup == null) { @@ -573,14 +584,16 @@ } else if ($leaf == null) { - $this->_cache[$group][$subgroup]['value'] = $ret['value']; - $this->_cache[$group][$subgroup]['timestamp'] = $ret['timestamp']; + $this->_cache[$group]['childs'][$subgroup]['value'] = $ret['value']; + $this->_cache[$group]['childs'][$subgroup]['timestamp'] = $ret['timestamp']; } else { if ($withleafvalue) - $this->_cache[$group][$subgroup][$leaf]['value'] = $ret['value']; - $this->_cache[$group][$subgroup][$leaf]['timestamp'] = $ret['timestamp']; + $this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]['value'] = $ret['value']; + else + unset($this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]['value']); + $this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]['timestamp'] = $ret['timestamp']; } return $ret; @@ -596,21 +609,45 @@ */ function rmMeta($group, $subgroup = null, $leaf = null) { - echo "rmMeta($group, $subgroup, $leaf)\n"; - - print_r($this->_cache); + //echo "rmMeta($group, $subgroup, $leaf)\n"; + // if ($group == "channelid-to-nickid") + // { echo "avant\n"; print_r($this->_cache[$group]); } + // remove from the cache if ($group == null) $this->_cache = array(); else if ($subgroup == null) unset($this->_cache[$group]); else if ($leaf == null) - unset($this->_cache[$group][$subgroup]); + { + if (isset($this->_cache[$group]['value'])) + { + $i = array_search($subgroup,$this->_cache[$group]['value']); + if ($i !== FALSE) + { + unset($this->_cache[$group]['value'][$i]); + unset($this->_cache[$group]['timestamp'][$i]); + } + } + unset($this->_cache[$group]['childs'][$subgroup]); + } else - unset($this->_cache[$group][$subgroup][$leaf]); + { + if (isset($this->_cache[$group]['childs'][$subgroup]['value'])) + { + $i = array_search($leaf,$this->_cache[$group]['childs'][$subgroup]['value']); + if ($i !== FALSE) + { + unset($this->_cache[$group]['childs'][$subgroup]['value'][$i]); + unset($this->_cache[$group]['childs'][$subgroup]['timestamp'][$i]); + } + } + unset($this->_cache[$group]['childs'][$subgroup]['childs'][$leaf]); + } - print_r($this->_cache); + // if ($group == "channelid-to-nickid") + // { echo "apres\n"; print_r($this->_cache[$group]); } return $this->_container->rmMeta($group, $subgroup, $leaf); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-19 22:32:59
|
Revision: 903 http://svn.sourceforge.net/phpfreechat/?rev=903&view=rev Author: kerphi Date: 2006-12-19 14:32:45 -0800 (Tue, 19 Dec 2006) Log Message: ----------- add a testcase on rmMeta Modified Paths: -------------- trunk/testcase/container_generic.php Modified: trunk/testcase/container_generic.php =================================================================== --- trunk/testcase/container_generic.php 2006-12-19 17:56:01 UTC (rev 902) +++ trunk/testcase/container_generic.php 2006-12-19 22:32:45 UTC (rev 903) @@ -79,9 +79,10 @@ // on the channel $this->ct->createNick($chan, $nick, $nickid); - $this->ct->removeNick($chan, $nickid); + + $this->ct->removeNick($chan, $nickid); $isonline = ($this->ct->isNickOnline($chan, $nickid) >= 0); - $this->assertFalse($isonline, "nickname shouldn't be online on the channel"); + $this->assertFalse($isonline, "nickname shouldn't be online on the channel"); $isonline2 = ($this->ct->isNickOnline(NULL, $nickid) >= 0); $this->assertTrue($isonline2, "nickname should be online on the server"); @@ -89,7 +90,7 @@ $isonline = ($this->ct->isNickOnline(NULL, $nickid) >= 0); $this->assertFalse($isonline, "nickname shouldn't be online on the server"); } - + function test_getNickId_Generic() { $c =& $this->c; @@ -377,6 +378,33 @@ $this->assertEquals($subgroup1, $ret["value"][0], "the subgroup name is wrong"); $this->assertEquals($subgroup2, $ret["value"][1], "the subgroup name is wrong"); } + + function test_rmMeta_Generic() + { + $c =& $this->c; + $ct =& $this->ct; + + $prefix = __FUNCTION__; + $group = $prefix."_nickid-to-channelid"; + $subgroup1 = $prefix."_nickid1"; + $subgroup2 = $prefix."_nickid2"; + $leaf1 = $prefix."_channelid1"; + $leaf2 = $prefix."_channelid2"; + $ct->setMeta($group, $subgroup1, $leaf1); + $ct->setMeta($group, $subgroup1, $leaf2); + + $ret = $ct->getMeta($group,$subgroup1); + $ret = $ct->getMeta($group,$subgroup1,$leaf1); + + $ct->rmMeta($group, $subgroup1, $leaf1); + + $ret = $ct->getMeta($group,$subgroup1); + $this->assertEquals(1, count($ret["value"]), "number of leaf is wrong"); + $ret = $ct->getMeta($group,$subgroup1,$leaf1); + $this->assertEquals(0, count($ret["value"]), "leaf should not exists"); + } + + } ?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-19 17:56:06
|
Revision: 902 http://svn.sourceforge.net/phpfreechat/?rev=902&view=rev Author: kerphi Date: 2006-12-19 09:56:01 -0800 (Tue, 19 Dec 2006) Log Message: ----------- Container optimization : add a memory cache (work in progress: do not update this revision !!!) Modified Paths: -------------- trunk/src/containers/file.class.php trunk/src/pfccontainer.class.php trunk/src/pfcglobalconfig.class.php Added Paths: ----------- trunk/src/pfccontainerinterface.class.php Modified: trunk/src/containers/file.class.php =================================================================== --- trunk/src/containers/file.class.php 2006-12-18 09:16:01 UTC (rev 901) +++ trunk/src/containers/file.class.php 2006-12-19 17:56:01 UTC (rev 902) @@ -20,24 +20,19 @@ * Boston, MA 02110-1301 USA */ -require_once dirname(__FILE__)."/../pfccontainer.class.php"; +require_once dirname(__FILE__)."/../pfccontainerinterface.class.php"; /** * pfcContainer_File is a concret container which stock data into files * * @author Stephane Gully <ste...@gm...> */ -class pfcContainer_File extends pfcContainer +class pfcContainer_File extends pfcContainerInterface { var $_users = array("nickid" => array(), "timestamp" => array()); var $_meta = array(); - function pfcContainer_File(&$config) - { - pfcContainer::pfcContainer($config); - } - function loadPaths() { $c =& $this->c; @@ -91,7 +86,7 @@ { if (file_exists($leaffilename) && filesize($leaffilename)>0) unlink($leaffilename); - touch($leaffilename); + touch($leaffilename); } else { @@ -122,7 +117,6 @@ $dir_base = $c->container_cfg_server_dir; $dir = $dir_base.'/'.$group; - if ($subgroup == NULL) { if (is_dir($dir)) @@ -154,6 +148,7 @@ } closedir($dh); } + return $ret; } Modified: trunk/src/pfccontainer.class.php =================================================================== --- trunk/src/pfccontainer.class.php 2006-12-18 09:16:01 UTC (rev 901) +++ trunk/src/pfccontainer.class.php 2006-12-19 17:56:01 UTC (rev 902) @@ -20,6 +20,8 @@ * Boston, MA 02110-1301 USA */ + require_once dirname(__FILE__)."/pfccontainerinterface.class.php"; + /** * pfcContainer is an abstract class which define interface * to be implemented by concrete container (example: File) @@ -27,13 +29,20 @@ * @author Stephane Gully <ste...@gm...> * @abstract */ -class pfcContainer +class pfcContainer extends pfcContainerInterface { - var $c; - function pfcContainer(&$config) { $this->c =& $config; } - function getDefaultConfig() { return array(); } - function init() { return array(); } + var $_container = null; // contains the concrete container instance + + function pfcContainer(&$c, $type = 'File') + { + pfcContainerInterface::pfcContainerInterface($c); + // create the concrete container instance + require_once dirname(__FILE__)."/containers/".strtolower($type).".class.php"; + $container_classname = "pfcContainer_".$type; + $this->_container =& new $container_classname($this->c); + } + /** * Create (connect/join) the nickname into the server or the channel locations * Notice: the caller must take care to update all channels the users joined (use stored channel list into metadata) @@ -280,7 +289,7 @@ { if ($chan == NULL) $chan = 'SERVER'; - $ret = $this->getMeta("channelid-to-nickid", $this->encode($chan)); + $ret = $this->getMeta("channelid-to-nickid", $this->encode($chan)); for($i = 0; $i<count($ret['timestamp']); $i++) { if ($ret['value'][$i] == $nickid) return $i; @@ -411,7 +420,6 @@ return $lastmsgid; } - /** * Remove all created data for this server (identified by serverid) * Notice: for the default File container, it's just a recursive directory remove @@ -421,25 +429,6 @@ $this->rmMeta(NULL); } - /** - * In the default File container: used to encode UTF8 strings to ASCII filenames - * This method can be overridden by the concrete container - */ - function encode($str) - { - return $str; - } - - /** - * In the default File container: used to decode ASCII filenames to UTF8 strings - * This method can be overridden by the concrete container - */ - function decode($str) - { - return $str; - } - - function getAllUserMeta($nickid) { $result = array(); @@ -483,7 +472,9 @@ $ret = $this->setMeta("channelid-to-metadata", $this->encode($chan), $key, $value); return $ret; } - + + var $_cache = array(); + /** * Write a meta data value identified by a group / subgroup / leaf [with a value] * As an example in the default file container this arborescent structure is modelised by simple directories @@ -499,8 +490,24 @@ * @return 1 if the old leaf has been overwritten, 0 if a new leaf has been created */ function setMeta($group, $subgroup, $leaf, $leafvalue = NULL) - { die(_pfc("%s must be implemented", get_class($this)."::".__FUNCTION__)); } + { + $ret = $this->_container->setMeta($group, $subgroup, $leaf, $leafvalue); + echo "setMeta($group, $subgroup, $leaf, $leafvalue)\n"; + //print_r($ret); + + + // @todo creer la bonne hierarchie du cache + + //$this->_cache['group'][$group] = array_merge($this->_cache['group'][$group],array($subgroup)); + //$this->_cache[$group][$subgroup][$leaf] = $leafvalue; + + //$this->_cache['subgroup'][$group][$subgroup] = $ret; + //$this->_cache['leaf'][$group][$subgroup][$leaf] = ($withleafvalue ? ; + + return $ret; + } + /** * Read meta data identified by a group [/ subgroup [/ leaf]] @@ -511,7 +518,73 @@ * @return array which contains two subarray 'timestamp' and 'value' */ function getMeta($group, $subgroup = null, $leaf = null, $withleafvalue = false) - { die(_pfc("%s must be implemented", get_class($this)."::".__FUNCTION__)); } + { + echo "getMeta($group, $subgroup, $leaf, $withleafvalue)\n"; + + // check in the cache + $ret = array('timestamp' => array(), + 'value' => array()); + if ($subgroup == null && + isset($this->_cache[$group]['value'])) + { + $ret['timestamp'] = $this->_cache[$group]['timestamp']; + $ret['value'] = $this->_cache[$group]['value']; + echo "getMeta->incache\n"; + return $ret; + } + else if ($leaf == null && + isset($this->_cache[$group][$subgroup]['value'])) + { + $ret['timestamp'] = $this->_cache[$group][$subgroup]['timestamp']; + $ret['value'] = $this->_cache[$group][$subgroup]['value']; + echo "getMeta->incache\n"; + return $ret; + } + else + { + if ($withleafvalue) + { + if (isset($this->_cache[$group][$subgroup][$leaf]['value'])) + { + echo "getMeta->incache\n"; + return $this->_cache[$group][$subgroup][$leaf]; + } + } + else + { + if (isset($this->_cache[$group][$subgroup][$leaf]['timestamp'])) + { + echo "getMeta->incache\n"; + return $this->_cache[$group][$subgroup][$leaf]; + } + } + } + + echo "getMeta->notincache\n"; + + // get the fresh data + $ret = $this->_container->getMeta($group, $subgroup, $leaf, $withleafvalue); + + // store in the cache + if ($subgroup == null) + { + $this->_cache[$group]['value'] = $ret['value']; + $this->_cache[$group]['timestamp'] = $ret['timestamp']; + } + else if ($leaf == null) + { + $this->_cache[$group][$subgroup]['value'] = $ret['value']; + $this->_cache[$group][$subgroup]['timestamp'] = $ret['timestamp']; + } + else + { + if ($withleafvalue) + $this->_cache[$group][$subgroup][$leaf]['value'] = $ret['value']; + $this->_cache[$group][$subgroup][$leaf]['timestamp'] = $ret['timestamp']; + } + + return $ret; + } /** @@ -522,8 +595,43 @@ * @return true on success, false on error */ function rmMeta($group, $subgroup = null, $leaf = null) - { die(_pfc("%s must be implemented", get_class($this)."::".__FUNCTION__)); } + { + echo "rmMeta($group, $subgroup, $leaf)\n"; + + print_r($this->_cache); + // remove from the cache + if ($group == null) + $this->_cache = array(); + else if ($subgroup == null) + unset($this->_cache[$group]); + else if ($leaf == null) + unset($this->_cache[$group][$subgroup]); + else + unset($this->_cache[$group][$subgroup][$leaf]); + + print_r($this->_cache); + + return $this->_container->rmMeta($group, $subgroup, $leaf); + } + + /** + * In the default File container: used to encode UTF8 strings to ASCII filenames + * This method can be overridden by the concrete container + */ + function encode($str) + { + return $this->_container->encode($str); + } + + /** + * In the default File container: used to decode ASCII filenames to UTF8 strings + * This method can be overridden by the concrete container + */ + function decode($str) + { + return $this->_container->decode($str); + } } ?> \ No newline at end of file Added: trunk/src/pfccontainerinterface.class.php =================================================================== --- trunk/src/pfccontainerinterface.class.php (rev 0) +++ trunk/src/pfccontainerinterface.class.php 2006-12-19 17:56:01 UTC (rev 902) @@ -0,0 +1,96 @@ +<?php +/** + * pfccontainerinterface.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 + */ + +/** + * pfcContainerInterface is an interface implemented by pfcContainer and each pfcContainer concrete isntances (File,Mysql...) + * + * @author Stephane Gully <ste...@gm...> + * @abstract + */ +class pfcContainerInterface +{ + var $c; + function pfcContainerInterface(&$config) { $this->c =& $config; } + function getDefaultConfig() { return array(); } + function init() { return array(); } + + /** + * Write a meta data value identified by a group / subgroup / leaf [with a value] + * As an example in the default file container this arborescent structure is modelised by simple directories + * group1/subgroup1/leaf1 + * /leaf2 + * /subgroup2/... + * Each leaf can contain or not a value. + * However each leaf and each group/subgroup must store the lastmodified time (timestamp). + * @param $group root arborescent element + * @param $subgroup is the root first child which contains leafs + * @param $leaf is the only element which can contain values + * @param $leafvalue NULL means the leaf will not contain any values + * @return 1 if the old leaf has been overwritten, 0 if a new leaf has been created + */ + function setMeta($group, $subgroup, $leaf, $leafvalue = NULL) + { die(_pfc("%s must be implemented", get_class($this)."::".__FUNCTION__)); } + + + /** + * Read meta data identified by a group [/ subgroup [/ leaf]] + * @param $group is mandatory, it's the arborescence's root + * @param $subgroup if null then the subgroup list names are returned + * @param $leaf if null then the leaf names are returned + * @param $withleafvalue if set to true the leaf value will be returned + * @return array which contains two subarray 'timestamp' and 'value' + */ + function getMeta($group, $subgroup = null, $leaf = null, $withleafvalue = false) + { die(_pfc("%s must be implemented", get_class($this)."::".__FUNCTION__)); } + + + /** + * Remove a meta data or a group of metadata + * @param $group if null then it will remove all the possible groups (all the created metadata) + * @param $subgroup if null then it will remove the $group's childs (all the subgroup contained by $group) + * @param $leaf if null then it will remove all the $subgroup's childs (all the leafs contained by $subgroup) + * @return true on success, false on error + */ + function rmMeta($group, $subgroup = null, $leaf = null) + { die(_pfc("%s must be implemented", get_class($this)."::".__FUNCTION__)); } + + + /** + * In the default File container: used to encode UTF8 strings to ASCII filenames + * This method can be overridden by the concrete container + */ + function encode($str) + { + return $str; + } + + /** + * In the default File container: used to decode ASCII filenames to UTF8 strings + * This method can be overridden by the concrete container + */ + function decode($str) + { + return $str; + } +} + +?> \ No newline at end of file Modified: trunk/src/pfcglobalconfig.class.php =================================================================== --- trunk/src/pfcglobalconfig.class.php 2006-12-18 09:16:01 UTC (rev 901) +++ trunk/src/pfcglobalconfig.class.php 2006-12-19 17:56:01 UTC (rev 902) @@ -235,6 +235,7 @@ */ function &getContainerInstance() { + // bug in php4: cant make a static pfcContainer instance because // it make problems with pfcGlobalConfig references (not updated) // it works well in php5, maybe there is a workeround but I don't have time to debug this @@ -243,11 +244,10 @@ // static $container; // if (!isset($container)) // { - $container_classname = "pfcContainer_".$this->container_type; - require_once dirname(__FILE__)."/containers/".strtolower($this->container_type).".class.php"; - $container =& new $container_classname($this); + require_once dirname(__FILE__).'/pfccontainer.class.php'; + $container =& new pfcContainer($this,$this->container_type); + return $container; // } - return $container; } /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-18 09:16:10
|
Revision: 901 http://svn.sourceforge.net/phpfreechat/?rev=901&view=rev Author: kerphi Date: 2006-12-18 01:16:01 -0800 (Mon, 18 Dec 2006) Log Message: ----------- adjust some promoted links Modified Paths: -------------- trunk/demo/index.php trunk/index.php Modified: trunk/demo/index.php =================================================================== --- trunk/demo/index.php 2006-12-18 09:13:04 UTC (rev 900) +++ trunk/demo/index.php 2006-12-18 09:16:01 UTC (rev 901) @@ -45,8 +45,8 @@ <a href="http://www.phpfreechat.net"><img alt="phpfreechat.net" src="../style/logo_88x31.gif" /></a><br/> <a href="http://sourceforge.net/projects/phpfreechat"><img src="http://sflogo.sourceforge.net/sflogo.php?group_id=158880&type=1" alt="SourceForge.net Logo" height="31px" width="88px" /></a><br/><br/> <a href="http://www.hotscripts.com/?RID=N452772">hotscripts.com</a><br/> - <a href="http://www.jeu-gratuit.net/?refer=phpfreechat">jeu-gratuit.net</a><br/> - <a href="http://www.pronofun.com/?refer=phpfreechat">pronofun.com</a><br/> + <a href="http://www.jeu-gratuit.net/">jeu-gratuit.net</a><br/> + <a href="http://www.pronofun.com/">pronofun.com</a><br/> </p> </div> Modified: trunk/index.php =================================================================== --- trunk/index.php 2006-12-18 09:13:04 UTC (rev 900) +++ trunk/index.php 2006-12-18 09:16:01 UTC (rev 901) @@ -98,8 +98,8 @@ <a href="http://www.phpfreechat.net"><img alt="phpfreechat.net" src="style/logo_88x31.gif" /></a><br/> <a href="http://sourceforge.net/projects/phpfreechat"><img src="http://sflogo.sourceforge.net/sflogo.php?group_id=158880&type=1" alt="SourceForge.net Logo" height="31px" width="88px" /></a><br/><br/> <a href="http://www.hotscripts.com/?RID=N452772">hotscripts.com</a><br/> - <a href="http://www.jeu-gratuit.net/?refer=phpfreechat">jeu-gratuit.net</a><br/> - <a href="http://www.pronofun.com/?refer=phpfreechat">pronofun.com</a><br/> + <a href="http://www.jeu-gratuit.net/">jeu-gratuit.net</a><br/> + <a href="http://www.pronofun.com/">pronofun.com</a><br/> </p> </div> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-18 09:13:07
|
Revision: 900 http://svn.sourceforge.net/phpfreechat/?rev=900&view=rev Author: kerphi Date: 2006-12-18 01:13:04 -0800 (Mon, 18 Dec 2006) Log Message: ----------- documentation : replace hard files links by html links to phpfreechat website (because it's considered by duplicate content by google) Modified Paths: -------------- trunk/index.php trunk/misc/tarSource trunk/version Modified: trunk/index.php =================================================================== --- trunk/index.php 2006-12-17 17:11:13 UTC (rev 899) +++ trunk/index.php 2006-12-18 09:13:04 UTC (rev 900) @@ -53,43 +53,43 @@ <li> <ul> <li class="item"> - <a href="overview.en.html">Overview [en]</a> + <a href="http://www.phpfreechat.net/overview.en.html">Overview [en]</a> </li> <li class="item"> - <a href="overview.fr.html">Overview [fr]</a> + <a href="http://www.phpfreechat.net/overview.fr.html">Overview [fr]</a> </li> <li class="item"> - <a href="overview.es.html">Overview [es]</a> + <a href="http://www.phpfreechat.net/overview.es.html">Overview [es]</a> </li> <li class="item"> - <a href="overview.ar.html">Overview [zh]</a> + <a href="http://www.phpfreechat.net/overview.ar.html">Overview [zh]</a> </li> <li class="item"> - <a href="overview.ar.html">Overview [ar]</a> + <a href="http://www.phpfreechat.net/overview.ar.html">Overview [ar]</a> </li> <li class="item"> - <a href="install.en.html">Install [en]</a> + <a href="http://www.phpfreechat.net/install.en.html">Install [en]</a> </li> <li class="item"> - <a href="install.fr.html">Install [fr]</a> + <a href="http://www.phpfreechat.net/install.fr.html">Install [fr]</a> </li> <li class="item"> - <a href="faq.en.html">FAQ [en]</a> + <a href="http://www.phpfreechat.net/faq.en.html">FAQ [en]</a> </li> <li class="item"> - <a href="faq.fr.html">FAQ [fr]</a> + <a href="http://www.phpfreechat.net/faq.fr.html">FAQ [fr]</a> </li> <li class="item"> - <a href="customize.en.html">Customize [en]</a> + <a href="http://www.phpfreechat.net/customize.en.html">Customize [en]</a> </li> <li class="item"> - <a href="customize.fr.html">Customize [fr]</a> + <a href="http://www.phpfreechat.net/customize.fr.html">Customize [fr]</a> </li> <li class="item"> - <a href="changelog.en.html">ChangeLog [en]</a> + <a href="http://www.phpfreechat.net/changelog.en.html">ChangeLog [en]</a> </li> <li class="item"> - <a href="changelog.fr.html">ChangeLog [fr]</a> + <a href="http://www.phpfreechat.net/changelog.fr.html">ChangeLog [fr]</a> </li> </ul> </li> Modified: trunk/misc/tarSource =================================================================== --- trunk/misc/tarSource 2006-12-17 17:11:13 UTC (rev 899) +++ trunk/misc/tarSource 2006-12-18 09:13:04 UTC (rev 900) @@ -10,20 +10,20 @@ rm -rf ./$NAME/contrib rm -rf ./$NAME/admin -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 "-> 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/version =================================================================== --- trunk/version 2006-12-17 17:11:13 UTC (rev 899) +++ trunk/version 2006-12-18 09:13:04 UTC (rev 900) @@ -1 +1 @@ -1.0-beta8-pre +1.0-beta8 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-17 17:11:21
|
Revision: 899 http://svn.sourceforge.net/phpfreechat/?rev=899&view=rev Author: kerphi Date: 2006-12-17 09:11:13 -0800 (Sun, 17 Dec 2006) Log Message: ----------- [en] Add the Romanian translation (thanks to Bindila Eduard Catalin) [0h15] [fr] Ajout de la traduction Roumaine (merci ?\195?\160 Bindila Eduard Catalin) [0h15] Modified Paths: -------------- trunk/demo/index.php Added Paths: ----------- trunk/demo/demo56_in_romanian.php trunk/i18n/uk_RO/ trunk/i18n/uk_RO/admin.php trunk/i18n/uk_RO/main.php Added: trunk/demo/demo56_in_romanian.php =================================================================== --- trunk/demo/demo56_in_romanian.php (rev 0) +++ trunk/demo/demo56_in_romanian.php 2006-12-17 17:11:13 UTC (rev 899) @@ -0,0 +1,36 @@ +<?php + +require_once dirname(__FILE__)."/../src/phpfreechat.class.php"; + +$params["serverid"] = md5(__FILE__); // calculate a unique id for this chat +$params["language"] = "uk_RO"; +$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> + <meta http-equiv="content-type" content="text/html; charset=utf-8" /> + <title>phpFreeChat demo</title> + + <?php $chat->printJavascript(); ?> + <?php $chat->printStyle(); ?> + + </head> + + <body> + <?php $chat->printChat(); ?> + +<?php + // print the current file + echo "<h2>The source code</h2>"; + $filename = __FILE__; + echo "<p><code>".$filename."</code></p>"; + echo "<pre style=\"margin: 0 50px 0 50px; padding: 10px; background-color: #DDD;\">"; + $content = file_get_contents($filename); + echo htmlentities($content); + echo "</pre>"; +?> + + </body> +</html> Modified: trunk/demo/index.php =================================================================== --- trunk/demo/index.php 2006-12-10 11:43:09 UTC (rev 898) +++ trunk/demo/index.php 2006-12-17 17:11:13 UTC (rev 899) @@ -121,6 +121,7 @@ <li><a href="demo52_in_bangla.php">demo52 - the Bangla translation of the chat</a></li> <li><a href="demo53_in_armenian.php">demo53 - the Armenian translation of the chat</a></li> <li><a href="demo54_in_esperanto.php">demo54 - the Esperanto translation of the chat</a></li> + <li><a href="demo56_in_romanian.php">demo56 - the Romanian translation of the chat</a></li> </ul> </div> Added: trunk/i18n/uk_RO/admin.php =================================================================== --- trunk/i18n/uk_RO/admin.php (rev 0) +++ trunk/i18n/uk_RO/admin.php 2006-12-17 17:11:13 UTC (rev 899) @@ -0,0 +1,72 @@ +<?php +/** + * i18n/uk_RO/main.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 + */ + +/** + * Romanian translation of the messages (utf8 encoded!) + * + * @author Bindila Eduard Catalin + */ + +$GLOBALS["i18n"]["lang"] = "Romana"; + +// admin/index.php +$GLOBALS["i18n"]["Administration"] = "Administrare"; +$GLOBALS["i18n"]["Available Languages"] = "Limbi valabile"; +$GLOBALS["i18n"]["PFC version verification"] = "Verificare versiune PFC "; +$GLOBALS["i18n"]["Internet connection is not possible"] = "Conectarea nu este posibila "; +$GLOBALS["i18n"]["PFC is update"] = "PFC este update"; +$GLOBALS["i18n"]["PFC version"] = "Versiune PFC "; +$GLOBALS["i18n"]["The last official version"] = "Ultima versiune oficiala"; +$GLOBALS["i18n"]["PFC is not update"] = "PFC nu este update"; +$GLOBALS["i18n"]["Your version"] = "Versiunea ta"; +$GLOBALS["i18n"]["Download the last version %s here %s."] = "Donwloadeaza ultima versiune %s aici %s."; + + +// admin/user.php +$GLOBALS["i18n"]["Users management"] = "Administrare useri"; +$GLOBALS["i18n"]["At least one user must be declare to activate authentication."] = "Cel putin un user trebuie declarat pentru a activa autentificarea."; +$GLOBALS["i18n"]["It is not possible to delete the last user."] = "Nu este posibila stergera ultimului user."; + +$GLOBALS["i18n"]["User %s deleted."] = "Userul %s a fost sters."; +$GLOBALS["i18n"]["User %s added."] = "Userul %s a fost adaugat."; +$GLOBALS["i18n"]["User %s edited."] = "Userul %s a fost editat."; + +$GLOBALS["i18n"]["Authentication disable"] = "Autentificare dezactivata"; +$GLOBALS["i18n"]["Enable here"] = "Activeazsa aici"; +$GLOBALS["i18n"]["Authentication enable"] = "Autentificare activata"; +$GLOBALS["i18n"]["Disable here"] = "Dezactiveaza aici"; + +$GLOBALS["i18n"]["Username"] = "Nume"; +$GLOBALS["i18n"]["Password"] = "Parola"; +$GLOBALS["i18n"]["Group"] = "Grup"; + +$GLOBALS["i18n"]["Do you really want to delete %s ?"] = "Sigur vrei sa stergi userul %s ?"; +$GLOBALS["i18n"]["Add a new user"] = "Adauga user"; + +$GLOBALS["i18n"]["Edit"] = "Editeaza"; +$GLOBALS["i18n"]["Delete"] = "Sterge"; + +// admin/themes.php +$GLOBALS["i18n"]["Available themes"] = "Teme valabile"; +$GLOBALS["i18n"]["Screenshot"] = "Imagini"; + +?> \ No newline at end of file Added: trunk/i18n/uk_RO/main.php =================================================================== --- trunk/i18n/uk_RO/main.php (rev 0) +++ trunk/i18n/uk_RO/main.php 2006-12-17 17:11:13 UTC (rev 899) @@ -0,0 +1,309 @@ +<?php +/** + * i18n/uk_RO/main.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 + */ + +/** + * Romanian translation of the messages (utf8 encoded!) + * + * @author Bindila Eduard Catalin + */ + +// line 45 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["My Chat"] = "Chat-ul meu"; + +// line 201 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s not found, %s library can't be found."] = "fisierul %s nu a fost gasit, %s libriaria nu este gasita."; + +// line 355 in phpfreechat.class.php +$GLOBALS["i18n"]["Please enter your nickname"] = "Te rog sa introduci un nume (nick)"; + +// line 565 in phpfreechat.class.php +$GLOBALS["i18n"]["Text cannot be empty"] = "Textul nu poate fi gol"; + +// line 392 in phpfreechat.class.php +$GLOBALS["i18n"]["%s changes his nickname to %s"] = "%s si-a schimbat nick-ul in %s"; + +// line 398 in phpfreechat.class.php +$GLOBALS["i18n"]["%s is connected"] = "%s s-a conectat"; + +// line 452 in phpfreechat.class.php +$GLOBALS["i18n"]["%s quit"] = "%s a iesit"; + +// line 468 in phpfreechat.class.php +$GLOBALS["i18n"]["%s disconnected (timeout)"] = "%s a fost deconectat (timeout) "; + +// line 262 in phpfreechat.class.php +$GLOBALS["i18n"]["Unknown command [%s]"] = "Comanda necunoscuta [%s]"; + +// line 149 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s doesn't exist: %s"] = "%s nu exista: %s"; + +// line 180 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["You need %s"] = "Ai nevoie de %s"; + +// line 241 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s doesn't exist, %s library can't be found"] = "%s nu exista, %s libraria nu a fost gasita"; + +// line 280 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s doesn't exist"] = "%s nu exista"; + +// line 433 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s directory must be specified"] = "%s directorul trebuie specificat"; + +// line 439 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s must be a directory"] = "%s trebuie sa fie un director"; + +// line 446 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s can't be created"] = "%s nu poate fi creat"; + +// line 451 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s is not writeable"] = "%s nu poate fi scris"; + +// line 496 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s is not readable"] = "%s nu poate fi citit"; + +// line 469 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s is not a file"] = "%s nu este un fisier"; + +// line 491 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s is not a directory"] = "%s nu este director"; + +// line 23 in chat.html.tpl.php +$GLOBALS["i18n"]["PHP FREE CHAT [powered by phpFreeChat-%s]"] = "PHP FREE CHAT [powered by phpFreeChat-%s]"; + +// line 296 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Hide nickname marker"] = "AScunde culorile nickurilor"; + +// line 304 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Show nickname marker"] = "Arata culorile nickuriloe"; + +// line 389 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Disconnect"] = "Deconectare"; + +// line 395 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Connect"] = "Conectare"; + +// line 427 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Magnify"] = "Mareste"; + +// line 434 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Cut down"] = "Taie"; + +// line 345 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Hide dates and hours"] = "AScunde data si ora"; + +// line 353 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Show dates and hours"] = "Arata data si ora"; + +// line 21 in chat.html.tpl.php +$GLOBALS["i18n"]["Enter your message here"] = "Introdu mesajul aici"; + +// line 24 in chat.html.tpl.php +$GLOBALS["i18n"]["Enter your nickname here"] = "Te rog sa introduci nickul aici"; + +// line 93 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["Error: undefined or obsolete parameter '%s', please correct or remove this parameter"] = "EROARE: parametru nedefinit: '%s', te rog corecteaza acest parametru"; + +// line 86 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Hide smiley box"] = "Ascunde panoul cu Zambete"; + +// line 87 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Show smiley box"] = "Arata panoul cu Zambete"; + +// line 88 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Hide online users box"] = "AScunde panoul cu userii online"; + +// line 89 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Show online users box"] = "Arata panoul cu userii online"; + +// line 33 in chat.html.tpl.php +$GLOBALS["i18n"]["Bold"] = "Bold"; + +// line 34 in chat.html.tpl.php +$GLOBALS["i18n"]["Italics"] = "Italic"; + +// line 35 in chat.html.tpl.php +$GLOBALS["i18n"]["Underline"] = "Subliniat"; + +// line 36 in chat.html.tpl.php +$GLOBALS["i18n"]["Delete"] = "Sterge"; + +// line 37 in chat.html.tpl.php +$GLOBALS["i18n"]["Pre"] = "Pre"; + +// line 38 in chat.html.tpl.php +$GLOBALS["i18n"]["Mail"] = "Mail"; + +// line 39 in chat.html.tpl.php +$GLOBALS["i18n"]["Color"] = "Culoare"; + +// line 48 in phpfreechattemplate.class.php +$GLOBALS["i18n"]["%s template could not be found"] = "%s template negasit"; + +// line 512 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["Error: '%s' could not be found, please check your themepath '%s' and your theme '%s' are correct"] = "EROARE: '%s' nu a fost gasit, te rog verifica calea temei tale '%s' si daca fisierul '%s' este corect"; + +// line 75 in pfccommand.class.php +$GLOBALS["i18n"]["%s must be implemented"] = "%s trebuie implementat"; + + +// line 343 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["'%s' parameter is mandatory by default use '%s' value"] = "'%s' parametrul este mandatar '%s' ca valoare"; + +// line 378 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be a positive number"] = "'%s' parameter must be a positive number"; + +// line 386 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["'%s' parameter is not valid. Available values are : '%s'"] = "'%s' parametrul nu este valid.Valorile valabile sunt: '%s'"; + +// line 185 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["My room"] = "Camera mea"; + +// line 109 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Private message"] = "Mesaj privat"; + +// line 110 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Close this tab"] = "Inchide aceasta fereastra"; + +// line 225 in pfcgui.js.tpl.php +$GLOBALS["i18n"]["Do you really want to leave this room ?"] = "Chiar vrei sa parasesti aceasta camera ?"; + +// line 19 in unban.class.php +$GLOBALS["i18n"]["Missing parameter"] = "Lipseste un parametru"; + +// line 38 in ban.class.php +$GLOBALS["i18n"]["banished from %s by %s"] = "banat din %s de %s"; + +// line 23 in banlist.class.php +$GLOBALS["i18n"]["The banished user's id list is:"] = "Lista cu ID-uri banate:"; + +// line 32 in banlist.class.php +$GLOBALS["i18n"]["Empty"] = "Gol"; + +// line 34 in banlist.class.php +$GLOBALS["i18n"]["'/unban {id}' will unban the user identified by {id}"] = "'/unban {id}' va scoate balu pentru {id}"; + +// line 35 in banlist.class.php +$GLOBALS["i18n"]["'/unban all' will unban all the users on this channel"] = "'/unban all' va scoate banul pentru toti userii de pe acest canal"; + +// line 24 in update.class.php +$GLOBALS["i18n"]["%s quit (timeout)"] = "%s a iesit (timeout)"; + +// line 46 in join.class.php +$GLOBALS["i18n"]["%s joins %s"] = "%s intra pe %s"; + +// line 31 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s"] = "A luat kick pe %s de la %s"; + +// line 38 in send.class.php +$GLOBALS["i18n"]["Can't send the message, %s is offline"] = "Nu pot trimite mesaj, %s este offline"; + +// line 27 in unban.class.php +$GLOBALS["i18n"]["Nobody has been unbanished"] = "Nimanui nu i s-a scos banul "; + +// line 42 in unban.class.php +$GLOBALS["i18n"]["%s has been unbanished"] = " I s-a scos banul lui %s"; + +// line 49 in unban.class.php +$GLOBALS["i18n"]["%s users have been unbanished"] = " Userilor %s li s-au scos banul "; + +// line 47 in auth.class.php +$GLOBALS["i18n"]["You are not allowed to run '%s' command"] = "Nu ai voie sa folosesti comanda aceasta '%s' "; + +// line 67 in auth.class.php +$GLOBALS["i18n"]["Can't join %s because you are banished"] = "Nu poti intra in %s pentru ca ai ban!"; + +// line 79 in auth.class.php +$GLOBALS["i18n"]["You are not allowed to change your nickname"] = "Nu ai voie sa-ti schimbi numele"; + +// line 76 in auth.class.php +$GLOBALS["i18n"]["Can't join %s because the channels list is restricted"] = "Nu poti intra pe %s pentru ca lista cu canale este restrictionatat"; + +// line 56 in noflood.class.php +$GLOBALS["i18n"]["Please don't post so many message, flood is not tolerated"] = "Te rog nu posta atatea mesaje, flood-ul nu va fi tolerat"; + +// line 169 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["Error: '%s' is a private parameter, you are not allowed to change it"] = "EROARE: '%s' este un parametru privat, nu ai voie sa-l schimbi"; + +// line 253 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be an array"] = "'%s' acest parametru trebuie sa fie vector (array)"; + +// line 265 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be a boolean"] = "'%s' acest parametru trebuie sa fie bulean"; + +// line 271 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be a charatere string"] = "'%s' acest parametru trebuie sa fie caracter string"; + +// line 395 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' must be writable"] = "'%s' trebuie sa fie scris"; + +// line 425 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' directory doesn't exist"] = "'%s' directorul nu exista"; + +// line 544 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["Please correct these errors"] = "Please correct these errors"; + +// line 21 in pfcinfo.class.php +$GLOBALS["i18n"]["Error: the cached config file doesn't exists"] = "EROARE: fisierul de configurare a cache nu este gasit"; + +// line 190 in phpfreechat.class.php +$GLOBALS["i18n"]["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"] = "EROARE: chatul nu poate fi incarcat! Exista 2 posibilitati: browserul tau nu suporta javascript sau nu ai setat corect drepturile pentru directoare - nu ezita sa ceri ajutor pe forum"; + +// line 31 in help.class.php +$GLOBALS["i18n"]["Here is the command list:"] = "Lista cu comenzi:"; + +// line 63 in identify.class.php +$GLOBALS["i18n"]["Succesfully identified"] = "Identificare facuta cu succes"; + +// line 68 in identify.class.php +$GLOBALS["i18n"]["Identification failure"] = "Identificare nereusita"; + +// line 25 in send.class.php +$GLOBALS["i18n"]["Your must be connected to send a message"] = "Trebuie sa fii conectat pen tru a trimite un mesaj"; + +// line 87 in chat.js.tpl.php +$GLOBALS["i18n"]["Click here to send your message"] = "Click aici pentru a trimite un mesaj"; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["Enter the text to format"] = "introdu textul pentru format"; + +// line 81 in chat.js.tpl.php +$GLOBALS["i18n"]["Configuration has been rehashed"] = "Configurarea a fost resetata"; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["A problem occurs during rehash"] = "O problema a aparut in timpul restartului"; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is allready used"] = "Alege alt nick acesta este deja folosit"; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["phpfreechat current version is %s"] = "versiunea curenta de phpfreechat %s"; + +// line 85 in chat.js.tpl.php +$GLOBALS["i18n"]["Maximum number of joined channels has been reached"] = "Numarul maxim de useri a fost atins"; + +// line 86 in chat.js.tpl.php +$GLOBALS["i18n"]["Maximum number of private chat has been reached"] = "Numarul de chaturi private a fost atins"; + +// line 88 in chat.js.tpl.php +$GLOBALS["i18n"]["Send"] = "Trimite"; + +?> \ 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-12-10 11:43:10
|
Revision: 898 http://svn.sourceforge.net/phpfreechat/?rev=898&view=rev Author: kerphi Date: 2006-12-10 03:43:09 -0800 (Sun, 10 Dec 2006) Log Message: ----------- [en] Turkish translation update (thanks to Mehmet Olduz) [0h10] [fr] Mise ?\195?\160 jour de la traduction turque (merci ?\195?\160 Mehmet Olduz) [0h10] Modified Paths: -------------- trunk/i18n/tr_TR/main.php Modified: trunk/i18n/tr_TR/main.php =================================================================== --- trunk/i18n/tr_TR/main.php 2006-12-09 21:07:47 UTC (rev 897) +++ trunk/i18n/tr_TR/main.php 2006-12-10 11:43:09 UTC (rev 898) @@ -24,6 +24,7 @@ * Turkish translation of the messages (utf8 encoded!) * * @author Mesut Soner Ermis <me...@er...> + * @revision Mehmet Olduz <meh...@ya...> */ // line 45 in phpfreechatconfig.class.php @@ -33,13 +34,13 @@ $GLOBALS["i18n"]["%s not found, %s library can't be found."] = "%s bulunamadı, %s kütüphanesi bulunamadı."; // line 355 in phpfreechat.class.php -$GLOBALS["i18n"]["Please enter your nickname"] = "Lütfen Nickinizi yazınız"; +$GLOBALS["i18n"]["Please enter your nickname"] = "Lütfen Takma adınızı yazınız"; // line 565 in phpfreechat.class.php $GLOBALS["i18n"]["Text cannot be empty"] = "Yazı boş olamaz"; // line 392 in phpfreechat.class.php -$GLOBALS["i18n"]["%s changes his nickname to %s"] = "%s nickini %s olarak değiştirdi"; +$GLOBALS["i18n"]["%s changes his nickname to %s"] = "%s takma adını %s olarak değiştirdi"; // line 398 in phpfreechat.class.php $GLOBALS["i18n"]["%s is connected"] = "%s sohbete katıldı.."; @@ -48,7 +49,7 @@ $GLOBALS["i18n"]["%s quit"] = "%s sohbetten ayrıldı.."; // line 468 in phpfreechat.class.php -$GLOBALS["i18n"]["%s disconnected (timeout)"] = "%s kullanıcısının bağlantısı koptu (timeout)"; +$GLOBALS["i18n"]["%s disconnected (timeout)"] = "%s kullanıcısının bağlantısı koptu (zaman-aşımı)"; // line 262 in phpfreechat.class.php $GLOBALS["i18n"]["Unknown command [%s]"] = "Geçersiz komut [%s]"; @@ -87,13 +88,13 @@ $GLOBALS["i18n"]["%s is not a directory"] = "%s bir klasör değil"; // line 23 in chat.html.tpl.php -$GLOBALS["i18n"]["PHP FREE CHAT [powered by phpFreeChat-%s]"] = "Sohbet Odası [powered by phpFreeChat-%s]"; +$GLOBALS["i18n"]["PHP FREE CHAT [powered by phpFreeChat-%s]"] = "Sohbet Odası [phpFreeChat-%s tarafından geliştirilmiştir]"; // line 296 in javascript1.js.tpl.php -$GLOBALS["i18n"]["Hide nickname marker"] = "Nickname renklerini gizle"; +$GLOBALS["i18n"]["Hide nickname marker"] = "Takma adların renklerini gizle"; // line 304 in javascript1.js.tpl.php -$GLOBALS["i18n"]["Show nickname marker"] = "Nickname renklerini göster"; +$GLOBALS["i18n"]["Show nickname marker"] = "Takma adların renklerini göster"; // line 389 in javascript1.js.tpl.php $GLOBALS["i18n"]["Disconnect"] = "Bağlantıyı Kes"; @@ -117,16 +118,16 @@ $GLOBALS["i18n"]["Enter your message here"] = "Mesajınızı buraya yazın.."; // line 24 in chat.html.tpl.php -$GLOBALS["i18n"]["Enter your nickname here"] = "Nickinizi buraya yazın"; +$GLOBALS["i18n"]["Enter your nickname here"] = "Takma adınızı buraya yazın"; // line 93 in phpfreechatconfig.class.php $GLOBALS["i18n"]["Error: undefined or obsolete parameter '%s', please correct or remove this parameter"] = "HATA: tanımsız veya eski bi parametre girdiniz '%s'"; // line 86 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Hide smiley box"] = "Smile Panelini Gizle"; +$GLOBALS["i18n"]["Hide smiley box"] = "Yüz ifadeleri kutusunu Gizle"; // line 87 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Show smiley box"] = "Smile Panelini Göster"; +$GLOBALS["i18n"]["Show smiley box"] = "Yüz ifadeleri kutusunu Göster"; // line 88 in pfcclient.js.tpl.php $GLOBALS["i18n"]["Hide online users box"] = "Kullanıcı Listesini Gizle"; @@ -138,7 +139,7 @@ $GLOBALS["i18n"]["Bold"] = "Kalın"; // line 34 in chat.html.tpl.php -$GLOBALS["i18n"]["Italics"] = "Italic"; +$GLOBALS["i18n"]["Italics"] = "Eğik"; // line 35 in chat.html.tpl.php $GLOBALS["i18n"]["Underline"] = "Altıçizgili"; @@ -174,168 +175,134 @@ $GLOBALS["i18n"]["'%s' parameter is not valid. Available values are : '%s'"] = "'%s' parametresi geçerli değil. Geçerli değerler: '%s'"; // line 186 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["My room"] = ""; +$GLOBALS["i18n"]["My room"] = "Odam"; // line 19 in unban.class.php -$GLOBALS["i18n"]["Missing parameter"] = ""; +$GLOBALS["i18n"]["Missing parameter"] = "Eksik Bilgi"; // line 38 in ban.class.php -$GLOBALS["i18n"]["banished from %s by %s"] = ""; +$GLOBALS["i18n"]["banished from %s by %s"] = "%s yasaklanmış (%s tarafından)"; // line 23 in banlist.class.php -$GLOBALS["i18n"]["The banished user's id list is:"] = ""; +$GLOBALS["i18n"]["The banished user's id list is:"] = "Yasaklanmış kullanıcının ismi listede:"; // line 32 in banlist.class.php -$GLOBALS["i18n"]["Empty"] = ""; +$GLOBALS["i18n"]["Empty"] = "Boş"; // line 34 in banlist.class.php -$GLOBALS["i18n"]["'/unban {id}' will unban the user identified by {id}"] = ""; +$GLOBALS["i18n"]["'/unban {id}' will unban the user identified by {id}"] = "'/unban {id}' komutu {id} takma adlı kişinin yasağını kaldıracaktır"; // line 35 in banlist.class.php -$GLOBALS["i18n"]["'/unban all' will unban all the users on this channel"] = ""; +$GLOBALS["i18n"]["'/unban all' will unban all the users on this channel"] = "'/unban all' komutu bu kanaldaki tüm kullanıcıların yasağını kaldıracaktır"; // line 24 in update.class.php -$GLOBALS["i18n"]["%s quit (timeout)"] = ""; +$GLOBALS["i18n"]["%s quit (timeout)"] = "%s ayrıldı (zaman aşımı)"; // line 46 in join.class.php -$GLOBALS["i18n"]["%s joins %s"] = ""; +$GLOBALS["i18n"]["%s joins %s"] = "%s %s\ adlı odaya katıldı"; // line 31 in kick.class.php -$GLOBALS["i18n"]["kicked from %s by %s"] = ""; +$GLOBALS["i18n"]["kicked from %s by %s"] = "%s %s tarafından kapı dışarı edildi"; // line 38 in send.class.php -$GLOBALS["i18n"]["Can't send the message, %s is offline"] = ""; +$GLOBALS["i18n"]["Can't send the message, %s is offline"] = "Mesaj gönderilemiyor, %s şu anda çevrimdışı"; // line 27 in unban.class.php -$GLOBALS["i18n"]["Nobody has been unbanished"] = ""; +$GLOBALS["i18n"]["Nobody has been unbanished"] = "Kimse yasaklanmış durumda değil"; // line 42 in unban.class.php -$GLOBALS["i18n"]["%s has been unbanished"] = ""; +$GLOBALS["i18n"]["%s has been unbanished"] = "%s yasaklanmıştır"; // line 49 in unban.class.php -$GLOBALS["i18n"]["%s users have been unbanished"] = ""; +$GLOBALS["i18n"]["%s users have been unbanished"] = "%s kullanıcıları yasaklanmışlardır"; // line 47 in auth.class.php -$GLOBALS["i18n"]["You are not allowed to run '%s' command"] = ""; +$GLOBALS["i18n"]["You are not allowed to run '%s' command"] = "%s komutunu çalıştırmak için izniniz yoktur"; // line 66 in auth.class.php -$GLOBALS["i18n"]["Can't join %s because you are banished"] = ""; +$GLOBALS["i18n"]["Can't join %s because you are banished"] = "Yasaklanmış olduğunuzdan dolayı %s odasına katılamazsınız"; // line 76 in auth.class.php -$GLOBALS["i18n"]["Can't join %s because the channels list is restricted"] = ""; +$GLOBALS["i18n"]["Can't join %s because the channels list is restricted"] = "Bu kanal kısıtlı olduğundan dolayı %s odasına katılamazsınız"; // line 89 in auth.class.php -$GLOBALS["i18n"]["You are not allowed to change your nickname"] = ""; +$GLOBALS["i18n"]["You are not allowed to change your nickname"] = "Takma adınızı değiştirme izniniz yok"; // line 56 in noflood.class.php -$GLOBALS["i18n"]["Please don't post so many message, flood is not tolerated"] = ""; +$GLOBALS["i18n"]["Please don't post so many message, flood is not tolerated"] = "Lütfen bu kadar çok mesaj göndermeyelim, aşırı yükleme"; // line 109 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Private message"] = ""; +$GLOBALS["i18n"]["Private message"] = "Özel Mesajlaşma Başlat"; // line 110 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Close this tab"] = ""; +$GLOBALS["i18n"]["Close this tab"] = "Bu tabı kapat"; // line 199 in pfcgui.js.tpl.php -$GLOBALS["i18n"]["Do you really want to leave this room ?"] = ""; +$GLOBALS["i18n"]["Do you really want to leave this room ?"] = "Odadan ayrılmak istediğinizden emin misiniz ?"; // line 169 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["Error: '%s' is a private parameter, you are not allowed to change it"] = ""; +$GLOBALS["i18n"]["Error: '%s' is a private parameter, you are not allowed to change it"] = "HATA: %s özel bir parametre, bunu değiştirme izniniz yok"; // line 253 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' parameter must be an array"] = ""; +$GLOBALS["i18n"]["'%s' parameter must be an array"] = "%s parametresi bi dizi (array) olmak zorunda"; // line 265 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' parameter must be a boolean"] = ""; +$GLOBALS["i18n"]["'%s' parameter must be a boolean"] = "%s parametresi bir boolean (true/false) olmak zorunda"; // line 271 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' parameter must be a charatere string"] = ""; +$GLOBALS["i18n"]["'%s' parameter must be a charatere string"] = "%s parametresi bir karakterler dizisi (string) olmak zorunda"; // line 395 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' must be writable"] = ""; +$GLOBALS["i18n"]["'%s' must be writable"] = "%s'nin yazma izni açık olması gerekmekte"; // line 425 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' directory doesn't exist"] = ""; +$GLOBALS["i18n"]["'%s' directory doesn't exist"] = "%s klasörü bulunmamaktadır"; // line 544 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["Please correct these errors"] = ""; +$GLOBALS["i18n"]["Please correct these errors"] = "Lütfen bu hataları düzeltiniz"; // line 21 in pfcinfo.class.php -$GLOBALS["i18n"]["Error: the cached config file doesn't exists"] = ""; +$GLOBALS["i18n"]["Error: the cached config file doesn't exists"] = "HATA: Cachelenmiş ayar dosyası bulunmamaktadır"; // line 190 in phpfreechat.class.php -$GLOBALS["i18n"]["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"] = ""; +$GLOBALS["i18n"]["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"] = "HATA: chat açılamadı! iki ihtimal var: ya tarayıcınız javascript desteklemiyor ya da sunucu klasör izinlerinin ayarlarında hata var"; // line 31 in help.class.php -$GLOBALS["i18n"]["Here is the command list:"] = ""; +$GLOBALS["i18n"]["Here is the command list:"] = "Komut listesi aşağıda:"; // line 63 in identify.class.php -$GLOBALS["i18n"]["Succesfully identified"] = ""; +$GLOBALS["i18n"]["Succesfully identified"] = "Başarılı olarak tanındı"; // line 68 in identify.class.php -$GLOBALS["i18n"]["Identification failure"] = ""; +$GLOBALS["i18n"]["Identification failure"] = "Tanınma hatası"; // line 25 in send.class.php -$GLOBALS["i18n"]["Your must be connected to send a message"] = ""; +$GLOBALS["i18n"]["Your must be connected to send a message"] = "Mesaj gönderebilmek için bağlı olmanız gerekmekte"; // line 87 in chat.js.tpl.php -$GLOBALS["i18n"]["Click here to send your message"] = ""; +$GLOBALS["i18n"]["Click here to send your message"] = "Mesaj göndermek için buraya tıklayınız"; // line 80 in chat.js.tpl.php -$GLOBALS["i18n"]["Enter the text to format"] = ""; +$GLOBALS["i18n"]["Enter the text to format"] = "Yazı formatını giriniz"; // line 81 in chat.js.tpl.php -$GLOBALS["i18n"]["Configuration has been rehashed"] = ""; +$GLOBALS["i18n"]["Configuration has been rehashed"] = "Ayarlar tekrar okundu"; // line 82 in chat.js.tpl.php -$GLOBALS["i18n"]["A problem occurs during rehash"] = ""; +$GLOBALS["i18n"]["A problem occurs during rehash"] = "Tekrar okuma sırasında hata"; // line 83 in chat.js.tpl.php -$GLOBALS["i18n"]["Choosen nickname is allready used"] = ""; +$GLOBALS["i18n"]["Choosen nickname is allready used"] = "Seçtiğiniz takma ad başkası tarafından kullanılmakta"; // line 84 in chat.js.tpl.php -$GLOBALS["i18n"]["phpfreechat current version is %s"] = ""; +$GLOBALS["i18n"]["phpfreechat current version is %s"] = "Şu anki phpfreechat versiyonu %s"; // line 85 in chat.js.tpl.php -$GLOBALS["i18n"]["Maximum number of joined channels has been reached"] = ""; +$GLOBALS["i18n"]["Maximum number of joined channels has been reached"] = "Mümkün olabilecek en fazla ortak kanal sayısına erişildi"; // line 86 in chat.js.tpl.php -$GLOBALS["i18n"]["Maximum number of private chat has been reached"] = ""; +$GLOBALS["i18n"]["Maximum number of private chat has been reached"] = "Mümkün olabilecek en fazla özel kanal sayısına erişildi"; // line 88 in chat.js.tpl.php -$GLOBALS["i18n"]["Send"] = ""; - -// line 86 in mysql.class.php -$GLOBALS["i18n"]["Mysql container: connect error"] = ""; - -// line 101 in mysql.class.php -$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; - -// line 112 in mysql.class.php -$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; - -// line 80 in chat.js.tpl.php -$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; - -// line 82 in chat.js.tpl.php -$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; - -// line 83 in chat.js.tpl.php -$GLOBALS["i18n"]["Enable sound notifications"] = ""; - -// line 84 in chat.js.tpl.php -$GLOBALS["i18n"]["Disable sound notifications"] = ""; - -// line 23 in kick.class.php -$GLOBALS["i18n"]["no reason"] = ""; - -// line 24 in banlist.class.php -$GLOBALS["i18n"]["The banished user list is:"] = ""; - -// line 39 in banlist.class.php -$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; - -// line 43 in kick.class.php -$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; - -?> \ No newline at end of file +$GLOBALS["i18n"]["Send"] = "Gönder"; +?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-09 21:07:55
|
Revision: 897 http://svn.sourceforge.net/phpfreechat/?rev=897&view=rev Author: kerphi Date: 2006-12-09 13:07:47 -0800 (Sat, 09 Dec 2006) Log Message: ----------- [en] Makes possible to have commands with multi parameters. Quotes (") are used to identify parameters with spaces. see: http://www.phpfreechat.net/forum/viewtopic.php?id=872 [5h15] [fr] Rend possible les commandes ayant plusieurs param?\195?\168tres. Les doubles guillemets (") sont utilis?\195?\169s pour s?\195?\169parer les param?\195?\168tres contenant des espaces. cf: http://www.phpfreechat.net/forum/viewtopic.php?id=872 [5h15] Modified Paths: -------------- trunk/demo/demo15_multiple_channel.php trunk/demo/demo34_add_a_link_on_nicknames/mytheme/customize.js trunk/demo/demo50_data/mytheme/customize.js trunk/src/client/pfcclient.js trunk/src/client/pfcgui.js trunk/src/commands/asknick.class.php trunk/src/commands/ban.class.php trunk/src/commands/banlist.class.php trunk/src/commands/kick.class.php trunk/src/commands/leave.class.php trunk/src/commands/unban.class.php trunk/src/phpfreechat.class.php Modified: trunk/demo/demo15_multiple_channel.php =================================================================== --- trunk/demo/demo15_multiple_channel.php 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/demo/demo15_multiple_channel.php 2006-12-09 21:07:47 UTC (rev 897) @@ -24,8 +24,8 @@ <body> <p>Rooms list:</p> <ul> - <li><a href="#" onclick="pfc.sendRequest('/join', 'room1');">room1</a></li> - <li><a href="#" onclick="pfc.sendRequest('/join', 'room2');">room2</a></li> + <li><a href="#" onclick="pfc.sendRequest('/join room1');">room1</a></li> + <li><a href="#" onclick="pfc.sendRequest('/join room2');">room2</a></li> </ul> <?php $chat->printChat(); ?> Modified: trunk/demo/demo34_add_a_link_on_nicknames/mytheme/customize.js =================================================================== --- trunk/demo/demo34_add_a_link_on_nicknames/mytheme/customize.js 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/demo/demo34_add_a_link_on_nicknames/mytheme/customize.js 2006-12-09 21:07:47 UTC (rev 897) @@ -18,7 +18,7 @@ var a = document.createElement('a'); a.setAttribute('href', ''); a.pfc_nick = nicks[i]; - a.onclick = function(){pfc.sendRequest('/privmsg', this.pfc_nick); return false;} + a.onclick = function(){pfc.sendRequest('/privmsg "'+this.pfc_nick+'"'); return false;} a.appendChild(img); li.appendChild(a); } @@ -58,4 +58,4 @@ else nickdiv.appendChild(ul,fc); this.colorizeNicks(nickdiv); -} \ No newline at end of file +} Modified: trunk/demo/demo50_data/mytheme/customize.js =================================================================== --- trunk/demo/demo50_data/mytheme/customize.js 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/demo/demo50_data/mytheme/customize.js 2006-12-09 21:07:47 UTC (rev 897) @@ -38,7 +38,7 @@ a.pfc_parent = div; a.onclick = function(evt){ var nick = pfc.getUserMeta(this.pfc_nickid,'nick'); - pfc.sendRequest('/privmsg', nick); + pfc.sendRequest('/privmsg "'+nick+'"'); this.pfc_parent.style.display = 'none'; return false; } @@ -96,4 +96,4 @@ div.appendChild(img); this.nickwhoisbox[nickid] = div; - } \ No newline at end of file + } Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/client/pfcclient.js 2006-12-09 21:07:47 UTC (rev 897) @@ -138,7 +138,7 @@ if (nickname == '') nickname = this.nickname; var newnick = prompt(this.res.getLabel('Please enter your nickname'), nickname); if (newnick) - this.sendRequest('/nick', newnick); + this.sendRequest('/nick "'+newnick+'"'); }, /** @@ -158,7 +158,7 @@ this.askNick(this.nickname); else { - this.sendRequest('/nick', this.nickname); + this.sendRequest('/nick "'+this.nickname+'"'); } // give focus the the input text box if wanted @@ -266,34 +266,37 @@ for (var i=0; i<pfc_defaultchan.length; i++) { if (i<pfc_defaultchan.length-1) - cmd = "/join2"; + cmd = '/join2'; else - cmd = "/join"; - this.sendRequest(cmd, pfc_defaultchan[i]); + cmd = '/join'; + cmd += ' "'+pfc_defaultchan[i]+'"'; + this.sendRequest(cmd); } // now join channels comming from sessions for (var i=0; i<pfc_userchan.length; i++) { if (i<pfc_userchan.length-1) - cmd = "/join2"; + cmd = '/join2'; else - cmd = "/join"; - this.sendRequest(cmd, pfc_userchan[i]); + cmd = '/join'; + cmd += ' "'+pfc_userchan[i]+'"'; + this.sendRequest(cmd); } // join the default privmsg comming from the parameter list for (var i=0; i<pfc_defaultprivmsg.length; i++) { if (i<pfc_defaultprivmsg.length-1) - cmd = "/privmsg2"; + cmd = '/privmsg2'; else - cmd = "/privmsg"; - this.sendRequest(cmd, pfc_defaultprivmsg[i]); + cmd = '/privmsg'; + cmd += ' "'+pfc_defaultprivmsg[i]+'"'; + this.sendRequest(cmd); } // now join privmsg comming from the sessions for (var i=0; i<pfc_userprivmsg.length; i++) { - this.sendRequest("/privmsg", pfc_userprivmsg[i]); + this.sendRequest('/privmsg "'+pfc_userprivmsg[i]+'"'); } } @@ -457,7 +460,7 @@ var nickid = meta['users']['nickid'][i]; var nick = meta['users']['nick'][i]; var um = this.getAllUserMeta(nickid); - if (!um) this.sendRequest('/whois2', nick); + if (!um) this.sendRequest('/whois2 "'+nick+'"'); } // update the nick list display on the current channel @@ -541,7 +544,7 @@ // a user command cmd = wval.replace(re, '$1'); param = wval.replace(re, '$3'); - this.sendRequest(cmd, param.substr(0, pfc_max_text_len + this.clientid.length)); + this.sendRequest(cmd +' '+ param.substr(0, pfc_max_text_len + 2*this.clientid.length)); } else { @@ -558,7 +561,7 @@ if (this.current_text_color != '' && wval.length != '') wval = '[color=#' + this.current_text_color + '] ' + wval + ' [/color]'; - this.sendRequest('/send', wval); + this.sendRequest('/send '+ wval); } w.value = ''; return false; @@ -885,28 +888,14 @@ * Call the ajax request function * Will query the server */ - sendRequest: function(cmd, param) + sendRequest: function(cmd) { - var recipientid = this.gui.getTabId(); - - - var req = cmd+" "+this.clientid+" "+(recipientid==''?'0':recipientid)+(param?" "+param : ""); if (pfc_debug) - if (cmd != "/update") trace('sendRequest: '+req); - return eval('pfc_handleRequest(req);'); - }, - - // @todo remplacer sendRequest par cette fonction (cf /leave dans pfcgui.js) - sendRequest2: function(cmd) - { + if (cmd != "/update") trace('sendRequest: '+cmd); var rx = new RegExp('(^\/[^ ]+) *(.*)','ig'); - var ttt = cmd.split(rx); - var recipientid = this.gui.getTabId(); - var req = ttt[1]+" "+this.clientid+" "+(recipientid==''?'0':recipientid)+' '+ttt[2]; - if (pfc_debug) - if (cmd != "/update") trace('sendRequest: '+req); - return eval('pfc_handleRequest(req);'); + cmd = cmd.replace(rx, '$1 '+this.clientid+' '+(recipientid==''?'0':recipientid)+' $2'); + return eval('pfc_handleRequest(cmd);'); }, /** @@ -1028,7 +1017,7 @@ a.pfc_parent = div; a.onclick = function(evt){ var nick = pfc.getUserMeta(this.pfc_nickid,'nick'); - pfc.sendRequest('/privmsg', nick); + pfc.sendRequest('/privmsg "'+nick+'"'); this.pfc_parent.style.display = 'none'; return false; } Modified: trunk/src/client/pfcgui.js =================================================================== --- trunk/src/client/pfcgui.js 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/client/pfcgui.js 2006-12-09 21:07:47 UTC (rev 897) @@ -257,9 +257,12 @@ var a2 = document.createElement('a'); a2.pfc_tabid = tabid; a2.pfc_tabname = name; + a2.pfc_tabtype = type; a2.onclick = function(){ var res = confirm(pfc.res.getLabel('Do you really want to leave this room ?')); - if (res == true) pfc.sendRequest2('/leave "'+this.pfc_tabname+'"'); return false; + if (res == true) + pfc.sendRequest('/leave '+this.pfc_tabtype+' "'+this.pfc_tabname+'"'); + return false; } a2.alt = pfc.res.getLabel('Close this tab'); a2.title = a2.alt; Modified: trunk/src/commands/asknick.class.php =================================================================== --- trunk/src/commands/asknick.class.php 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/commands/asknick.class.php 2006-12-09 21:07:47 UTC (rev 897) @@ -34,7 +34,7 @@ } else $msg = "'".$nicktochange."' is used, please choose another nickname."; - $xml_reponse->addScript("var newnick = prompt('".addslashes($msg)."', '".addslashes($nicktochange)."'); if (newnick) pfc.sendRequest('/nick', newnick);"); + $xml_reponse->addScript("var newnick = prompt('".addslashes($msg)."', '".addslashes($nicktochange)."'); if (newnick) pfc.sendRequest('/nick \"'+newnick+'\"');"); } } } Modified: trunk/src/commands/ban.class.php =================================================================== --- trunk/src/commands/ban.class.php 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/commands/ban.class.php 2006-12-09 21:07:47 UTC (rev 897) @@ -18,7 +18,12 @@ $c =& $this->c; $u =& $this->u; - if (trim($params[0]) == '') + $nick = isset($params[0]) ? trim($params[0]) : ''; + $reason = isset($params[1]) ? $params[1] : ''; + if ($reason == '') $reason = _pfc("no reason"); + $channame = $u->channels[$recipientid]["name"]; + + if ($nick == '') { // error $cmdp = $p; @@ -30,11 +35,11 @@ } $ct =& $c->getContainerInstance(); - $nickidtoban = $ct->getNickId($params[0]); + $nickidtoban = $ct->getNickId($nick); // notify all the channel $cmdp = $p; - $cmdp["param"] = _pfc("banished from %s by %s", $recipient, $sender); + $cmdp["param"] = _pfc("banished from %s by %s", $channame, $sender); $cmdp["flag"] = 1; $cmd =& pfcCommand::Factory("notice"); $cmd->run($xml_reponse, $cmdp); @@ -42,8 +47,8 @@ // kick the user (maybe in the future, it will be dissociate in a /kickban command) $cmdp = $p; $cmdp["params"] = array(); - $cmdp["params"][] = $params[0]; // nickname to kick - $cmdp["params"][] = $params[1]; // reason + $cmdp["params"][] = $nick; // nickname to kick + $cmdp["params"][] = $reason; // reason $cmd =& pfcCommand::Factory("kick"); $cmd->run($xml_reponse, $cmdp); Modified: trunk/src/commands/banlist.class.php =================================================================== --- trunk/src/commands/banlist.class.php 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/commands/banlist.class.php 2006-12-09 21:07:47 UTC (rev 897) @@ -21,14 +21,14 @@ if ($banlist == NULL) $banlist = array(); else $banlist = unserialize($banlist); $msg = ""; - $msg .= "<p>"._pfc("The banished user's id list is:")."</p>"; + $msg .= "<p>"._pfc("The banished user list is:")."</p>"; if (count($banlist)>0) { $msg .= "<ul>"; foreach($banlist as $b) { $n = $ct->getNickname($b); - $msg .= "<li style=\"margin-left:50px\">".$b." (".$n.")</li>"; + $msg .= "<li style=\"margin-left:50px\">".$n."</li>"; } $msg .= "</ul>"; } @@ -36,7 +36,7 @@ { $msg .= "<p>("._pfc("Empty").")</p>"; } - $msg .= "<p>"._pfc("'/unban {id}' will unban the user identified by {id}")."</p>"; + $msg .= "<p>"._pfc("'/unban {nickname}' will unban the user identified by {nickname}")."</p>"; $msg .= "<p>"._pfc("'/unban all' will unban all the users on this channel")."</p>"; $xml_reponse->addScript("pfc.handleResponse('".$this->name."', 'ok', '".addslashes($msg)."');"); Modified: trunk/src/commands/kick.class.php =================================================================== --- trunk/src/commands/kick.class.php 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/commands/kick.class.php 2006-12-09 21:07:47 UTC (rev 897) @@ -18,7 +18,11 @@ $c =& $this->c; $u =& $this->u; - if (trim($params[0]) == '') + $nick = isset($params[0]) ? trim($params[0]) : ''; + $reason = isset($params[1]) ? $params[1] : ''; + if ($reason == '') $reason = _pfc("no reason"); + + if ($nick == '') { // error $cmdp = $p; @@ -31,12 +35,12 @@ // kicking a user just add a command to play to the aimed user metadata. $ct =& $c->getContainerInstance(); - $otherid = $ct->getNickId($params[0]); + $otherid = $ct->getNickId($nick); $channame = $u->channels[$recipientid]["name"]; $cmdstr = 'leave'; $cmdp = array(); $cmdp['params'][] = $channame; // channel name - $cmdp['params'][] = _pfc("kicked from %s by %s - reason: %s", $channame, $sender, $params[1]); // reason + $cmdp['params'][] = _pfc("kicked from %s by %s - reason: %s", $channame, $sender, $reason); // reason pfcCommand::AppendCmdToPlay($otherid, $cmdstr, $cmdp); } } Modified: trunk/src/commands/leave.class.php =================================================================== --- trunk/src/commands/leave.class.php 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/commands/leave.class.php 2006-12-09 21:07:47 UTC (rev 897) @@ -5,7 +5,7 @@ class pfcCommand_leave extends pfcCommand { - var $usage = "/leave [{channel} {reason}]"; + var $usage = "/leave [ch|pv [[{channel|nickname}] {reason}]]"; function run(&$xml_reponse, $p) { @@ -17,24 +17,55 @@ $c =& $this->c; $u =& $this->u; + $ct =& $c->getContainerInstance(); - // tab to leave can be passed in the parameters - // a reason can also be present (used for kick and ban commands) - $id = ''; $reason = ''; - if (count($params)>0) + $type = isset($params[0]) ? $params[0] : ''; + $name = isset($params[1]) ? $params[1] : ''; + $reason = isset($params[2]) ? $params[2] : ''; + + if ($type != 'ch' && $type != 'pv' && $type != '') { - $id = pfcCommand_join::GetRecipientId($params[0]); - $reason = implode(" ",array_slice($params,1)); + // error + $cmdp = $p; + $cmdp["param"] = _pfc("Missing parameter"); + $cmdp["param"] .= " (".$this->usage.")"; + $cmd =& pfcCommand::Factory("error"); + $cmd->run($xml_reponse, $cmdp); + return; } - if ($id == '') $id = $recipientid; // be default this is the current tab to leave + - // $xml_reponse->addScript("alert('sender=".addslashes($sender)."');"); - // $xml_reponse->addScript("alert('recipientid=".addslashes($id)."');"); + // get the recipientid to close (a pv or a channel) + $id = ''; + if ($type == 'ch') + { + if ($name == '') + $id = $recipientid; + else + $id = pfcCommand_join::GetRecipientId($name); + } + else if ($type == 'pv') + { + // pv + $pvnickid = $ct->getNickId($name); + $nickid = $u->nickid; + if ($pvnickid != '') + { + // generate a pvid from the two nicknames ids + $a = array($pvnickid, $nickid); sort($a); + $pvrecipient = "pv_".$a[0]."_".$a[1]; + $id = md5($pvrecipient); + } + } + else + $id = $recipientid; + + $leavech = false; $leavepv = false; - $leave_recip = ""; - $leave_id = ""; + $leave_recip = ''; + $leave_id = ''; // check into channels if ( isset($u->channels[$id]) ) @@ -72,7 +103,6 @@ } // remove the nickname from the channel/pv - $ct =& $c->getContainerInstance(); $ct->removeNick($leave_recip, $u->nickid); // reset the sessions indicators Modified: trunk/src/commands/unban.class.php =================================================================== --- trunk/src/commands/unban.class.php 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/commands/unban.class.php 2006-12-09 21:07:47 UTC (rev 897) @@ -4,12 +4,13 @@ class pfcCommand_unban extends pfcCommand { - var $usage = "/unban {id}"; + var $usage = "/unban {nickname}"; function run(&$xml_reponse, $p) { $clientid = $p["clientid"]; $param = $p["param"]; + $params = $p["params"]; $sender = $p["sender"]; $recipient = $p["recipient"]; $recipientid = $p["recipientid"]; @@ -17,9 +18,12 @@ $c =& $this->c; $u =& $this->u; - $container =& $c->getContainerInstance(); + $ct =& $c->getContainerInstance(); - if (trim($param) == "") + $nick = isset($params[0]) ? $params[0] : ''; + $nickid = $ct->getNickId($nick); + + if ($nick == "") { // error $cmdp = $p; @@ -29,29 +33,30 @@ $cmd->run($xml_reponse, $cmdp); return; } + $updated = false; $msg = "<p>"._pfc("Nobody has been unbanished")."</p>"; // update the recipient banlist - $banlist = $container->getChanMeta($recipient, 'banlist_nickid'); + $banlist = $ct->getChanMeta($recipient, 'banlist_nickid'); if ($banlist == NULL) $banlist = array(); else $banlist = unserialize($banlist); $nb = count($banlist); - if (in_array($param, $banlist)) + if (in_array($nickid, $banlist)) { - $banlist = array_diff($banlist, array($param)); - $container->setChanMeta($recipient, 'banlist_nickid', serialize($banlist)); + $banlist = array_diff($banlist, array($nickid)); + $ct->setChanMeta($recipient, 'banlist_nickid', serialize($banlist)); $updated = true; - $msg = "<p>"._pfc("%s has been unbanished", $param)."</p>"; + $msg = "<p>"._pfc("%s has been unbanished", $nick)."</p>"; } - else if ($param == "all") + else if ($nick == "all") // @todo move the "/unban all" command in another command /unbanall { $banlist = array(); - $container->setChanMeta($recipient, 'banlist_nickid', serialize($banlist)); + $ct->setChanMeta($recipient, 'banlist_nickid', serialize($banlist)); $updated = true; $msg = "<p>"._pfc("%s users have been unbanished", $nb)."</p>"; } Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-12-09 17:31:03 UTC (rev 896) +++ trunk/src/phpfreechat.class.php 2006-12-09 21:07:47 UTC (rev 897) @@ -339,7 +339,7 @@ $cmdname = strtolower(isset($res['cmdname']) ? $res['cmdname'] : ''); $clientid = isset($res['params'][0]) ? $res['params'][0] : ''; $recipientid = isset($res['params'][1]) ? $res['params'][1] : ""; - $params = array_slice($res['params'],2); + $params = array_slice(is_array($res['params']) ? $res['params'] : array() ,2); $param = implode(" ",$params); // to keep compatibility (will be removed) $sender = $u->nick; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-09 17:31:10
|
Revision: 896 http://svn.sourceforge.net/phpfreechat/?rev=896&view=rev Author: kerphi Date: 2006-12-09 09:31:03 -0800 (Sat, 09 Dec 2006) Log Message: ----------- update labels Modified Paths: -------------- trunk/i18n/ar_LB/main.php trunk/i18n/ba_BA/main.php trunk/i18n/bg_BG/main.php trunk/i18n/bn_BD/main.php trunk/i18n/de_DE-formal/main.php trunk/i18n/de_DE-informal/main.php trunk/i18n/el_GR/main.php trunk/i18n/en_US/main.php trunk/i18n/eo/main.php trunk/i18n/es_ES/main.php trunk/i18n/fr_FR/main.php trunk/i18n/hu_HU/main.php trunk/i18n/hy_AM/main.php trunk/i18n/id_ID/main.php trunk/i18n/it_IT/main.php trunk/i18n/ja_JP/main.php trunk/i18n/nb_NO/main.php trunk/i18n/nl_NL/main.php trunk/i18n/pl_PL/main.php trunk/i18n/pt_BR/main.php trunk/i18n/pt_PT/main.php trunk/i18n/ru_RU/main.php trunk/i18n/sr_CS/main.php trunk/i18n/sv_SE/main.php trunk/i18n/tr_TR/main.php trunk/i18n/uk_UA/main.php trunk/i18n/zh_CN/main.php trunk/i18n/zh_TW/main.php Modified: trunk/i18n/ar_LB/main.php =================================================================== --- trunk/i18n/ar_LB/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/ar_LB/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -327,4 +327,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/ba_BA/main.php =================================================================== --- trunk/i18n/ba_BA/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/ba_BA/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -330,4 +330,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/bg_BG/main.php =================================================================== --- trunk/i18n/bg_BG/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/bg_BG/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -325,4 +325,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/bn_BD/main.php =================================================================== --- trunk/i18n/bn_BD/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/bn_BD/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -331,4 +331,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/de_DE-formal/main.php =================================================================== --- trunk/i18n/de_DE-formal/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/de_DE-formal/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -330,4 +330,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/de_DE-informal/main.php =================================================================== --- trunk/i18n/de_DE-informal/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/de_DE-informal/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -331,4 +331,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/el_GR/main.php =================================================================== --- trunk/i18n/el_GR/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/el_GR/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -326,4 +326,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/en_US/main.php =================================================================== --- trunk/i18n/en_US/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/en_US/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -327,4 +327,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = "Disable sound notifications"; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = "no reason"; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = "The banished user list is:"; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = "'/unban {nickname}' will unban the user identified by {nickname}"; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = "kicked from %s by %s - reason: %s"; + ?> \ No newline at end of file Modified: trunk/i18n/eo/main.php =================================================================== --- trunk/i18n/eo/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/eo/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -330,4 +330,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/es_ES/main.php =================================================================== --- trunk/i18n/es_ES/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/es_ES/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -326,4 +326,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/fr_FR/main.php =================================================================== --- trunk/i18n/fr_FR/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/fr_FR/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -327,4 +327,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = "Désactiver la notification sonore"; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = "pas de raison"; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = "La liste des utilisateurs bannis est :"; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = "'/unban {id}' va débannir l'utilisateur identifié par {nickname}"; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = "kické de %s par %s"; + ?> \ No newline at end of file Modified: trunk/i18n/hu_HU/main.php =================================================================== --- trunk/i18n/hu_HU/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/hu_HU/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -329,4 +329,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/hy_AM/main.php =================================================================== --- trunk/i18n/hy_AM/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/hy_AM/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -330,4 +330,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/id_ID/main.php =================================================================== --- trunk/i18n/id_ID/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/id_ID/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -330,4 +330,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/it_IT/main.php =================================================================== --- trunk/i18n/it_IT/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/it_IT/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -330,4 +330,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/ja_JP/main.php =================================================================== --- trunk/i18n/ja_JP/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/ja_JP/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -328,4 +328,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/nb_NO/main.php =================================================================== --- trunk/i18n/nb_NO/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/nb_NO/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -327,4 +327,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/nl_NL/main.php =================================================================== --- trunk/i18n/nl_NL/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/nl_NL/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -328,4 +328,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/pl_PL/main.php =================================================================== --- trunk/i18n/pl_PL/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/pl_PL/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -328,4 +328,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/pt_BR/main.php =================================================================== --- trunk/i18n/pt_BR/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/pt_BR/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -330,4 +330,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/pt_PT/main.php =================================================================== --- trunk/i18n/pt_PT/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/pt_PT/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -328,4 +328,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/ru_RU/main.php =================================================================== --- trunk/i18n/ru_RU/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/ru_RU/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -332,4 +332,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/sr_CS/main.php =================================================================== --- trunk/i18n/sr_CS/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/sr_CS/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -330,4 +330,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/sv_SE/main.php =================================================================== --- trunk/i18n/sv_SE/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/sv_SE/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -335,4 +335,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/tr_TR/main.php =================================================================== --- trunk/i18n/tr_TR/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/tr_TR/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -326,4 +326,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/uk_UA/main.php =================================================================== --- trunk/i18n/uk_UA/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/uk_UA/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -327,4 +327,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/zh_CN/main.php =================================================================== --- trunk/i18n/zh_CN/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/zh_CN/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -331,4 +331,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/zh_TW/main.php =================================================================== --- trunk/i18n/zh_TW/main.php 2006-12-08 17:58:25 UTC (rev 895) +++ trunk/i18n/zh_TW/main.php 2006-12-09 17:31:03 UTC (rev 896) @@ -327,4 +327,16 @@ // line 84 in chat.js.tpl.php $GLOBALS["i18n"]["Disable sound notifications"] = ""; +// line 23 in kick.class.php +$GLOBALS["i18n"]["no reason"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user list is:"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {nickname}' will unban the user identified by {nickname}"] = ""; + +// line 43 in kick.class.php +$GLOBALS["i18n"]["kicked from %s by %s - reason: %s"] = ""; + ?> \ 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-12-08 17:58:33
|
Revision: 895 http://svn.sourceforge.net/phpfreechat/?rev=895&view=rev Author: kerphi Date: 2006-12-08 09:58:25 -0800 (Fri, 08 Dec 2006) Log Message: ----------- work in progress : multi parameters in commands Modified Paths: -------------- trunk/src/client/pfcclient.js trunk/src/client/pfcgui.js trunk/src/commands/ban.class.php trunk/src/commands/invite.class.php trunk/src/commands/kick.class.php trunk/src/commands/leave.class.php trunk/src/pfccommand.class.php trunk/src/phpfreechat.class.php Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-12-08 13:55:33 UTC (rev 894) +++ trunk/src/client/pfcclient.js 2006-12-08 17:58:25 UTC (rev 895) @@ -888,12 +888,27 @@ sendRequest: function(cmd, param) { var recipientid = this.gui.getTabId(); + + var req = cmd+" "+this.clientid+" "+(recipientid==''?'0':recipientid)+(param?" "+param : ""); if (pfc_debug) if (cmd != "/update") trace('sendRequest: '+req); return eval('pfc_handleRequest(req);'); }, + // @todo remplacer sendRequest par cette fonction (cf /leave dans pfcgui.js) + sendRequest2: function(cmd) + { + var rx = new RegExp('(^\/[^ ]+) *(.*)','ig'); + var ttt = cmd.split(rx); + + var recipientid = this.gui.getTabId(); + var req = ttt[1]+" "+this.clientid+" "+(recipientid==''?'0':recipientid)+' '+ttt[2]; + if (pfc_debug) + if (cmd != "/update") trace('sendRequest: '+req); + return eval('pfc_handleRequest(req);'); + }, + /** * update function to poll the server each 'refresh_delay' time */ Modified: trunk/src/client/pfcgui.js =================================================================== --- trunk/src/client/pfcgui.js 2006-12-08 13:55:33 UTC (rev 894) +++ trunk/src/client/pfcgui.js 2006-12-08 17:58:25 UTC (rev 895) @@ -256,9 +256,10 @@ { var a2 = document.createElement('a'); a2.pfc_tabid = tabid; + a2.pfc_tabname = name; a2.onclick = function(){ var res = confirm(pfc.res.getLabel('Do you really want to leave this room ?')); - if (res == true) pfc.sendRequest('/leave', this.pfc_tabid); return false; + if (res == true) pfc.sendRequest2('/leave "'+this.pfc_tabname+'"'); return false; } a2.alt = pfc.res.getLabel('Close this tab'); a2.title = a2.alt; Modified: trunk/src/commands/ban.class.php =================================================================== --- trunk/src/commands/ban.class.php 2006-12-08 13:55:33 UTC (rev 894) +++ trunk/src/commands/ban.class.php 2006-12-08 17:58:25 UTC (rev 895) @@ -4,12 +4,13 @@ class pfcCommand_ban extends pfcCommand { - var $usage = "/ban {nickname}"; + var $usage = "/ban {nickname} [ {reason} ]"; function run(&$xml_reponse, $p) { $clientid = $p["clientid"]; $param = $p["param"]; + $params = $p["params"]; $sender = $p["sender"]; $recipient = $p["recipient"]; $recipientid = $p["recipientid"]; @@ -17,7 +18,7 @@ $c =& $this->c; $u =& $this->u; - if (trim($param) == "") + if (trim($params[0]) == '') { // error $cmdp = $p; @@ -28,33 +29,33 @@ return; } + $ct =& $c->getContainerInstance(); + $nickidtoban = $ct->getNickId($params[0]); + + // notify all the channel + $cmdp = $p; + $cmdp["param"] = _pfc("banished from %s by %s", $recipient, $sender); + $cmdp["flag"] = 1; + $cmd =& pfcCommand::Factory("notice"); + $cmd->run($xml_reponse, $cmdp); + + // kick the user (maybe in the future, it will be dissociate in a /kickban command) + $cmdp = $p; + $cmdp["params"] = array(); + $cmdp["params"][] = $params[0]; // nickname to kick + $cmdp["params"][] = $params[1]; // reason + $cmd =& pfcCommand::Factory("kick"); + $cmd->run($xml_reponse, $cmdp); - $container =& $c->getContainerInstance(); - $nickid = $container->getNickId($param); - if ($nickid != "") - { - $cmdtoplay = $container->getUserMeta($nickid, 'cmdtoplay'); - $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); - $cmdtmp = array("leave", /* cmdname */ - $recipientid,/* param */ - $sender, /* sender */ - $recipient, /* recipient */ - $recipientid,/* recipientid */ - ); - //_pfc("banished from %s by %s", $recipient, $sender); - $cmdtoplay[] = $cmdtmp; // ban the user from the current channel - $container->setUserMeta($nickid, 'cmdtoplay', serialize($cmdtoplay)); - } - // update the recipient banlist - $banlist = $container->getChanMeta($recipient, 'banlist_nickid'); + $banlist = $ct->getChanMeta($recipient, 'banlist_nickid'); if ($banlist == NULL) $banlist = array(); else $banlist = unserialize($banlist); - $banlist[] = $nickid; // append the nickid to the banlist - $container->setChanMeta($recipient, 'banlist_nickid', serialize($banlist)); + $banlist[] = $nickidtoban; // append the nickid to the banlist + $ct->setChanMeta($recipient, 'banlist_nickid', serialize($banlist)); } } Modified: trunk/src/commands/invite.class.php =================================================================== --- trunk/src/commands/invite.class.php 2006-12-08 13:55:33 UTC (rev 894) +++ trunk/src/commands/invite.class.php 2006-12-08 17:58:25 UTC (rev 895) @@ -1,5 +1,4 @@ <?php - /** * invite.class.php * @@ -20,7 +19,10 @@ * Free Software Foundation, 51 Franklin St, Fifth Floor, * Boston, MA 02110-1301 USA */ - + +require_once(dirname(__FILE__)."/../pfccommand.class.php"); +require_once(dirname(__FILE__)."/../commands/join.class.php"); + /** * /invite command * @@ -29,54 +31,56 @@ * The parameter "target channel" is optional, if not set it defaults to the current channel * * @author Benedikt Hallinger <be...@ph...> + * @author Stephane Gully <ste...@gm...> */ class pfcCommand_invite extends pfcCommand { - var $usage = "/invite {nickname to invite} [{target channel}]"; + var $usage = "/invite {nickname to invite} [ {target channel} ]"; - function run(&$xml_reponse, $p) - { - $clientid = $p["clientid"]; - $param = $p["param"]; - $sender = $p["sender"]; - $recipient = $p["recipient"]; - $recipientid = $p["recipientid"]; + function run(&$xml_reponse, $p) + { + $clientid = $p["clientid"]; + $param = $p["param"]; + $params = $p["params"]; + $sender = $p["sender"]; + $recipient = $p["recipient"]; + $recipientid = $p["recipientid"]; + + $c =& $this->c; // pfcGlobalConfig + $u =& $this->u; // pfcUserConfig + $ct =& $c->getContainerInstance(); // Connection to the chatbackend + + $nicktoinvite = isset($params[0]) ? $params[0] : ''; + $channeltarget = isset($params[1]) ? $params[1] : $u->channels[$recipientid]["name"]; // Default: current channel + + if ($nicktoinvite == '' || $channeltarget == '') + { + // Parameters are not ok + $cmdp = $p; + $cmdp["params"] = array(); + $cmdp["param"] = _pfc("Missing parameter"); + $cmdp["param"] .= " (".$this->usage.")"; + $cmd =& pfcCommand::Factory("error"); + $cmd->run($xml_reponse, $cmdp); + return; + } - $c =& $this->c; // pfcGlobalConfig - $u =& $this->u; // pfcUserConfig - $container =& $c->getContainerInstance(); // Connection to the chatbackend - - $p_array = split(' ', $param); // Split the parameters: [0]= targetnick, [1]=targetchannel - if (!isset($p_array[1])) $p_array[1] = $u->channels[$recipientid]["name"]; // Default: current channel - if (!isset($p_array[0]) || !isset($p_array[1])) - { - // Parameters not ok! - $cmdp = $p; - $cmdp["param"] = _pfc("Missing parameter"); - $cmdp["param"] .= " (".$this->usage.")"; - $cmd =& pfcCommand::Factory("error"); - $cmd->run($xml_reponse, $cmdp); - return; - } - - // inviting a user: just add a join command to play to the aimed user metadata. - $nickid = $container->getNickId($p_array[0]); // get the internal ID of that chatter - if ($nickid != "") - { - $cmdtoplay = $container->getUserMeta($nickid, 'cmdtoplay'); // get the users command queue - $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); - $cmdtmp = array("join", /* cmdname */ - $p_array[1], /* param */ - $sender, /* sender */ - $recipient, /* recipient */ - $recipientid,/* recipientid */ - ); - $cmdtoplay[] = $cmdtmp; // store the command in the queue - $container->setUserMeta($nickid, 'cmdtoplay', serialize($cmdtoplay)); // close and store the queue + // inviting a user: just add a join command to play to the aimed user metadata. + $nickidtoinvite = $ct->getNickId($nicktoinvite); + $cmdstr = 'join2'; + $cmdp = array(); + $cmdp['param'] = $channeltarget; // channel target name + $cmdp['params'][] = $channeltarget; // channel target name + pfcCommand::AppendCmdToPlay($nickidtoinvite, $cmdstr, $cmdp); - // Ok, the user is invited, now write something into the chat, so his tab opens - $container->write($recipient, 'SYSTEM', "notice", $p_array[0].' was invited by '.$sender); - } - } + // notify the aimed channel that a user has been invited + $cmdp = array(); + $cmdp["param"] = $nicktoinvite.' was invited by '.$sender; + $cmdp["flag"] = 1; + $cmdp["recipient"] = pfcCommand_join::GetRecipient($channeltarget); + $cmdp["recipientid"] = pfcCommand_join::GetRecipientId($channeltarget); + $cmd =& pfcCommand::Factory("notice"); + $cmd->run($xml_reponse, $cmdp); + } } ?> \ No newline at end of file Modified: trunk/src/commands/kick.class.php =================================================================== --- trunk/src/commands/kick.class.php 2006-12-08 13:55:33 UTC (rev 894) +++ trunk/src/commands/kick.class.php 2006-12-08 17:58:25 UTC (rev 895) @@ -4,12 +4,13 @@ class pfcCommand_kick extends pfcCommand { - var $usage = "/kick {nickname}"; + var $usage = "/kick {nickname} [ {reason} ]"; function run(&$xml_reponse, $p) { $clientid = $p["clientid"]; $param = $p["param"]; + $params = $p["params"]; $sender = $p["sender"]; $recipient = $p["recipient"]; $recipientid = $p["recipientid"]; @@ -17,7 +18,7 @@ $c =& $this->c; $u =& $this->u; - if (trim($param) == "") + if (trim($params[0]) == '') { // error $cmdp = $p; @@ -27,24 +28,16 @@ $cmd->run($xml_reponse, $cmdp); return; } - + // kicking a user just add a command to play to the aimed user metadata. - $container =& $c->getContainerInstance(); - $nickid = $container->getNickId($param); - if ($nickid != "") - { - $cmdtoplay = $container->getUserMeta($nickid, 'cmdtoplay'); - $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); - $reason = _pfc("kicked from %s by %s", $u->channels[$recipientid]["name"], $sender); - $cmdtmp = array("leave", /* cmdname */ - $recipientid." ".$reason, /* param */ - $sender, /* sender */ - $recipient, /* recipient */ - $recipientid,/* recipientid */ - ); - $cmdtoplay[] = $cmdtmp; // kick the user from the current channel - $container->setUserMeta($nickid, 'cmdtoplay', serialize($cmdtoplay)); - } + $ct =& $c->getContainerInstance(); + $otherid = $ct->getNickId($params[0]); + $channame = $u->channels[$recipientid]["name"]; + $cmdstr = 'leave'; + $cmdp = array(); + $cmdp['params'][] = $channame; // channel name + $cmdp['params'][] = _pfc("kicked from %s by %s - reason: %s", $channame, $sender, $params[1]); // reason + pfcCommand::AppendCmdToPlay($otherid, $cmdstr, $cmdp); } } Modified: trunk/src/commands/leave.class.php =================================================================== --- trunk/src/commands/leave.class.php 2006-12-08 13:55:33 UTC (rev 894) +++ trunk/src/commands/leave.class.php 2006-12-08 17:58:25 UTC (rev 895) @@ -1,15 +1,16 @@ <?php require_once(dirname(__FILE__)."/../pfccommand.class.php"); +require_once(dirname(__FILE__)."/../commands/join.class.php"); class pfcCommand_leave extends pfcCommand { - var $usage = "/leave [{recipientid} {reason}]"; + var $usage = "/leave [{channel} {reason}]"; function run(&$xml_reponse, $p) { $clientid = $p["clientid"]; - $param = $p["param"]; + $params = $p["params"]; $sender = $p["sender"]; $recipient = $p["recipient"]; $recipientid = $p["recipientid"]; @@ -19,13 +20,13 @@ // tab to leave can be passed in the parameters // a reason can also be present (used for kick and ban commands) - $id = ""; $reason = ""; - if (preg_match("/([a-z0-9]*)( (.*)|)/i", $param, $res)) + $id = ''; $reason = ''; + if (count($params)>0) { - $id = $res[1]; - $reason = trim($res[2]); + $id = pfcCommand_join::GetRecipientId($params[0]); + $reason = implode(" ",array_slice($params,1)); } - if ($id == "") $id = $recipientid; // be default this is the current tab to leave + if ($id == '') $id = $recipientid; // be default this is the current tab to leave // $xml_reponse->addScript("alert('sender=".addslashes($sender)."');"); // $xml_reponse->addScript("alert('recipientid=".addslashes($id)."');"); @@ -84,6 +85,15 @@ // reset the oldmsg flag $oldmsg_sid = "pfc_oldmsg_".$c->getId()."_".$clientid."_".$chanid; $_SESSION[$oldmsg_sid] = true; + + // if the /leave command comes from a cmdtoplay then show the reason to the user (ex: kick or ban reason) + if ($p['cmdtoplay']) + { + $cmdp = $p; + $cmdp["param"] = $reason; + $cmd =& pfcCommand::Factory("error"); + $cmd->run($xml_reponse, $cmdp); + } // return ok to the client // then the client will remove the channel' tab Modified: trunk/src/pfccommand.class.php =================================================================== --- trunk/src/pfccommand.class.php 2006-12-08 13:55:33 UTC (rev 894) +++ trunk/src/pfccommand.class.php 2006-12-08 17:58:25 UTC (rev 895) @@ -161,22 +161,88 @@ // alert them that $nicktorewhois user info just changed foreach($otherids as $otherid) { + $cmdstr = 'whois2'; + $cmdp = array(); + $cmdp['param'] = $nicktorewhois; + pfcCommand::AppendCmdToPlay($otherid, $cmdstr, $cmdp); + + /* $cmdtoplay = $ct->getUserMeta($otherid, 'cmdtoplay'); $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); - $cmdtmp = array("whois2", /* cmdname */ - $nicktorewhois, /* param */ - NULL, /* sender */ - NULL, /* recipient */ - NULL, /* recipientid */ + $cmdtmp = array("whois2", // cmdname + $nicktorewhois, // param + NULL, // sender + NULL, // recipient + NULL, // recipientid ); if (!in_array($cmdtmp, $cmdtoplay)) { $cmdtoplay[] = $cmdtmp; $ct->setUserMeta($otherid, 'cmdtoplay', serialize($cmdtoplay)); } + */ } } + function AppendCmdToPlay($nickid, $cmdstr, $cmdp) + { + $c =& pfcGlobalConfig::Instance(); + $u =& pfcUserConfig::Instance(); + + $ct =& $c->getContainerInstance(); + if ($nickid != "") + { + $cmdtoplay = $ct->getUserMeta($nickid, 'cmdtoplay'); + $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); + $cmdtmp = array(); + $cmdtmp['cmdstr'] = $cmdstr; + $cmdtmp['params'] = $cmdp; + $cmdtoplay[] = $cmdtmp; + $ct->setUserMeta($nickid, 'cmdtoplay', serialize($cmdtoplay)); + return true; + } + else + return false; + } + + function RunPendingCmdToPlay($nickid,$clientid,$xml_reponse) + { + $c =& pfcGlobalConfig::Instance(); + $u =& pfcUserConfig::Instance(); + $ct =& $c->getContainerInstance(); + + $morecmd = true; + while($morecmd) + { + // take a command from the list + $cmdtoplay = $ct->getUserMeta($nickid, 'cmdtoplay'); + $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); + if (count($cmdtoplay) == 0) { $morecmd = false; continue; } + // take the last posted command + $cmdtmp = array_pop($cmdtoplay); + // store the new cmdtoplay list (-1 item) + $ct->setUserMeta($nickid, 'cmdtoplay', serialize($cmdtoplay)); + + // play the command + // print_r($cmdtmp); + $cmd =& pfcCommand::Factory($cmdtmp['cmdstr']); + $cmdp = $cmdtmp['params']; + $cmdp['clientid'] = $clientid; // the clientid must be the current user one + $cmdp['cmdtoplay'] = true; // used to run some specials actions in the command (ex: if the cmdtoplay is a 'leave' command, then show an alert to the kicked or banished user) + if ($c->debug) + $cmd->run($xml_reponse, $cmdp); + else + @$cmd->run($xml_reponse, $cmdp); + + // check if there is other command to play + $cmdtoplay = $ct->getUserMeta($nickid, 'cmdtoplay'); + $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); + + $morecmd = (count($cmdtoplay) > 0); + } + } + + function trace(&$xml_reponse, $msg, $data = NULL) { if ($data != NULL) Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-12-08 13:55:33 UTC (rev 894) +++ trunk/src/phpfreechat.class.php 2006-12-08 17:58:25 UTC (rev 895) @@ -361,70 +361,21 @@ { // alert the other from the new pv // (warn other user that someone talk to him) - $container =& $c->getContainerInstance(); - $cmdtoplay = $container->getUserMeta($u->privmsg[$recipientid]["pvnickid"], 'cmdtoplay'); - $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); - $cmdtmp = array("privmsg2", /* cmdname */ - $u->nick, /* param */ - $sender, /* sender */ - $recipient, /* recipient */ - $recipientid,/* recipientid */ - ); - if (!in_array($cmdtmp, $cmdtoplay)) - { - $cmdtoplay[] = $cmdtmp; - $container->setUserMeta($u->privmsg[$recipientid]["pvnickid"], 'cmdtoplay', serialize($cmdtoplay)); - //$xml_reponse->addScript("alert('cmdtoplay[]=".serialize($cmdtoplay)."');"); - } + + $ct =& $c->getContainerInstance(); + $nickidtopv = $u->privmsg[$recipientid]["pvnickid"]; + $cmdstr = 'privmsg2'; + $cmdp = array(); + $cmdp['param'] = $u->nick; + $cmdp['params'][] = $u->nick; + pfcCommand::AppendCmdToPlay($nickidtopv, $cmdstr, $cmdp); } } - // before playing the wanted command // play the found commands into the meta 'cmdtoplay' - $container =& $c->getContainerInstance(); - $nickid = $u->nickid; - $morecmd = true; - while($morecmd) - { - // take a command from the list - $cmdtoplay = $container->getUserMeta($nickid, 'cmdtoplay'); - $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); - $cmdtmp = array_pop($cmdtoplay); - if ($cmdtmp != NULL) - { - // store the new cmdtoplay list (-1 item) - $container->setUserMeta($nickid, 'cmdtoplay', serialize($cmdtoplay)); - - // play the command - $cmd =& pfcCommand::Factory($cmdtmp[0]); - $cmdp = array(); - $cmdp["clientid"] = $clientid; - $cmdp["param"] = $cmdtmp[1]; - $cmdp["sender"] = $cmdtmp[2]; - $cmdp["recipient"] = $cmdtmp[3]; - $cmdp["recipientid"] = $cmdtmp[4]; - if ($c->debug) - $cmd->run($xml_reponse, $cmdp); - else - @$cmd->run($xml_reponse, $cmdp); - - // if the cmdtoplay is a 'leave' command, then show an alert to the kicked or banished user - if ($cmdtmp[0] == "leave") - { - if (preg_match("/([a-z0-9]*) (.*)/i", $cmdtmp[1], $res)) - $xml_reponse->addScript("alert('".$res[2]."');"); - } - - // check if there is other command to play - $cmdtoplay = $container->getUserMeta($nickid, 'cmdtoplay'); - $cmdtoplay = ($cmdtoplay == NULL) ? array() : unserialize($cmdtoplay); - } - - $morecmd = (count($cmdtoplay) > 0); - } - + pfcCommand::RunPendingCmdToPlay($u->nickid, $clientid, $xml_reponse); $cmd =& pfcCommand::Factory($cmdname); $cmdp = array(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-08 13:55:37
|
Revision: 894 http://svn.sourceforge.net/phpfreechat/?rev=894&view=rev Author: kerphi Date: 2006-12-08 05:55:33 -0800 (Fri, 08 Dec 2006) Log Message: ----------- update i18n labels Modified Paths: -------------- trunk/i18n/ar_LB/main.php trunk/i18n/ba_BA/main.php trunk/i18n/bg_BG/main.php trunk/i18n/bn_BD/main.php trunk/i18n/de_DE-formal/main.php trunk/i18n/de_DE-informal/main.php trunk/i18n/el_GR/main.php trunk/i18n/en_US/main.php trunk/i18n/eo/main.php trunk/i18n/es_ES/main.php trunk/i18n/fr_FR/main.php trunk/i18n/hu_HU/main.php trunk/i18n/hy_AM/main.php trunk/i18n/id_ID/main.php trunk/i18n/it_IT/main.php trunk/i18n/ja_JP/main.php trunk/i18n/nb_NO/main.php trunk/i18n/nl_NL/main.php trunk/i18n/pl_PL/main.php trunk/i18n/pt_BR/main.php trunk/i18n/pt_PT/main.php trunk/i18n/ru_RU/main.php trunk/i18n/sr_CS/main.php trunk/i18n/sv_SE/main.php trunk/i18n/tr_TR/main.php trunk/i18n/uk_UA/main.php trunk/i18n/zh_CN/main.php trunk/i18n/zh_TW/main.php trunk/src/client/chat.js.tpl.php trunk/src/client/pfcclient.js Modified: trunk/i18n/ar_LB/main.php =================================================================== --- trunk/i18n/ar_LB/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/ar_LB/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -306,4 +306,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/ba_BA/main.php =================================================================== --- trunk/i18n/ba_BA/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/ba_BA/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -309,4 +309,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/bg_BG/main.php =================================================================== --- trunk/i18n/bg_BG/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/bg_BG/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -304,4 +304,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/bn_BD/main.php =================================================================== --- trunk/i18n/bn_BD/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/bn_BD/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -306,4 +306,29 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "পাঠাও"; -?> + +// line 40 in banlist.class.php +$GLOBALS["i18n"]["'/unban all' will unban all the users on this channel"] = ""; + +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + +?> \ No newline at end of file Modified: trunk/i18n/de_DE-formal/main.php =================================================================== --- trunk/i18n/de_DE-formal/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/de_DE-formal/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -309,4 +309,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/de_DE-informal/main.php =================================================================== --- trunk/i18n/de_DE-informal/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/de_DE-informal/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -309,4 +309,26 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "Senden"; -?> + +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + +?> \ No newline at end of file Modified: trunk/i18n/el_GR/main.php =================================================================== --- trunk/i18n/el_GR/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/el_GR/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -305,4 +305,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/en_US/main.php =================================================================== --- trunk/i18n/en_US/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/en_US/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -306,4 +306,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "Send"; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = "Mysql container: connect error"; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = "Mysql container: create database error '%s'"; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = "Mysql container: create table error '%s'"; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = "You are not allowed to speak to yourself"; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = "Choosen nickname is not allowed"; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = "Enable sound notifications"; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = "Disable sound notifications"; + ?> \ No newline at end of file Modified: trunk/i18n/eo/main.php =================================================================== --- trunk/i18n/eo/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/eo/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -174,3 +174,160 @@ $GLOBALS["i18n"]["'%s' parameter is not valid. Available values are : '%s'"] = "'%s' parameter is not valid. Available values are: '%s'"; ?> +// line 183 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["Error: '%s' is a private parameter, you are not allowed to change it"] = ""; + +// line 211 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["My room"] = ""; + +// line 284 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be an array"] = ""; + +// line 296 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be a boolean"] = ""; + +// line 302 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be a charatere string"] = ""; + +// line 421 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' must be writable"] = ""; + +// line 454 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' directory doesn't exist"] = ""; + +// line 576 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["Please correct these errors"] = ""; + +// line 21 in pfcinfo.class.php +$GLOBALS["i18n"]["Error: the cached config file doesn't exists"] = ""; + +// line 191 in phpfreechat.class.php +$GLOBALS["i18n"]["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"] = ""; + +// line 26 in unban.class.php +$GLOBALS["i18n"]["Missing parameter"] = ""; + +// line 45 in ban.class.php +$GLOBALS["i18n"]["banished from %s by %s"] = ""; + +// line 24 in banlist.class.php +$GLOBALS["i18n"]["The banished user's id list is:"] = ""; + +// line 37 in banlist.class.php +$GLOBALS["i18n"]["Empty"] = ""; + +// line 39 in banlist.class.php +$GLOBALS["i18n"]["'/unban {id}' will unban the user identified by {id}"] = ""; + +// line 40 in banlist.class.php +$GLOBALS["i18n"]["'/unban all' will unban all the users on this channel"] = ""; + +// line 32 in help.class.php +$GLOBALS["i18n"]["Here is the command list:"] = ""; + +// line 64 in identify.class.php +$GLOBALS["i18n"]["Succesfully identified"] = ""; + +// line 69 in identify.class.php +$GLOBALS["i18n"]["Identification failure"] = ""; + +// line 49 in join.class.php +$GLOBALS["i18n"]["%s joins %s"] = ""; + +// line 81 in noflood.class.php +$GLOBALS["i18n"]["kicked from %s by %s"] = ""; + +// line 25 in send.class.php +$GLOBALS["i18n"]["Your must be connected to send a message"] = ""; + +// line 50 in send.class.php +$GLOBALS["i18n"]["Can't send the message, %s is offline"] = ""; + +// line 34 in unban.class.php +$GLOBALS["i18n"]["Nobody has been unbanished"] = ""; + +// line 49 in unban.class.php +$GLOBALS["i18n"]["%s has been unbanished"] = ""; + +// line 56 in unban.class.php +$GLOBALS["i18n"]["%s users have been unbanished"] = ""; + +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 53 in auth.class.php +$GLOBALS["i18n"]["You are not allowed to run '%s' command"] = ""; + +// line 73 in auth.class.php +$GLOBALS["i18n"]["Can't join %s because you are banished"] = ""; + +// line 83 in auth.class.php +$GLOBALS["i18n"]["Can't join %s because the channels list is restricted"] = ""; + +// line 57 in checknickchange.class.php +$GLOBALS["i18n"]["You are not allowed to change your nickname"] = ""; + +// line 59 in checktimeout.class.php +$GLOBALS["i18n"]["%s quit (timeout)"] = ""; + +// line 75 in noflood.class.php +$GLOBALS["i18n"]["Please don't post so many message, flood is not tolerated"] = ""; + +// line 46 in chat.js.tpl.php +$GLOBALS["i18n"]["Do you really want to leave this room ?"] = ""; + +// line 60 in chat.js.tpl.php +$GLOBALS["i18n"]["Private message"] = ""; + +// line 61 in chat.js.tpl.php +$GLOBALS["i18n"]["Close this tab"] = ""; + +// line 71 in chat.js.tpl.php +$GLOBALS["i18n"]["Enter the text to format"] = ""; + +// line 72 in chat.js.tpl.php +$GLOBALS["i18n"]["Configuration has been rehashed"] = ""; + +// line 73 in chat.js.tpl.php +$GLOBALS["i18n"]["A problem occurs during rehash"] = ""; + +// line 74 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is allready used"] = ""; + +// line 75 in chat.js.tpl.php +$GLOBALS["i18n"]["phpfreechat current version is %s"] = ""; + +// line 76 in chat.js.tpl.php +$GLOBALS["i18n"]["Maximum number of joined channels has been reached"] = ""; + +// line 77 in chat.js.tpl.php +$GLOBALS["i18n"]["Maximum number of private chat has been reached"] = ""; + +// line 78 in chat.js.tpl.php +$GLOBALS["i18n"]["Click here to send your message"] = ""; + +// line 79 in chat.js.tpl.php +$GLOBALS["i18n"]["Send"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 81 in chat.js.tpl.php +$GLOBALS["i18n"]["Close"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + +?> \ No newline at end of file Modified: trunk/i18n/es_ES/main.php =================================================================== --- trunk/i18n/es_ES/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/es_ES/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -305,4 +305,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/fr_FR/main.php =================================================================== --- trunk/i18n/fr_FR/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/fr_FR/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -306,4 +306,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "Envoyer"; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = "Erreur du conteneur mysql : connexion"; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = "Erreur du conteneur mysql : création de la base de donnée '%s'"; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = "Erreur du conteneur mysql : création de la table '%s'"; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = "Vous n'êtes pas autorisés à vous parler"; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = "Le pseudonyme choisi n'est pas autorisé"; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = "Activer la notification sonore"; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = "Désactiver la notification sonore"; + ?> \ No newline at end of file Modified: trunk/i18n/hu_HU/main.php =================================================================== --- trunk/i18n/hu_HU/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/hu_HU/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -308,4 +308,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/hy_AM/main.php =================================================================== --- trunk/i18n/hy_AM/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/hy_AM/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -308,4 +308,26 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "Ասել"; -?> + +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + +?> \ No newline at end of file Modified: trunk/i18n/id_ID/main.php =================================================================== --- trunk/i18n/id_ID/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/id_ID/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -309,4 +309,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/it_IT/main.php =================================================================== --- trunk/i18n/it_IT/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/it_IT/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -305,4 +305,29 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "Invia"; -?> + +// line 302 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be a charatere string"] = ""; + +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + +?> \ No newline at end of file Modified: trunk/i18n/ja_JP/main.php =================================================================== --- trunk/i18n/ja_JP/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/ja_JP/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -307,4 +307,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "送信する"; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/nb_NO/main.php =================================================================== --- trunk/i18n/nb_NO/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/nb_NO/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -306,4 +306,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/nl_NL/main.php =================================================================== --- trunk/i18n/nl_NL/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/nl_NL/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -307,4 +307,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/pl_PL/main.php =================================================================== --- trunk/i18n/pl_PL/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/pl_PL/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -307,4 +307,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/pt_BR/main.php =================================================================== --- trunk/i18n/pt_BR/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/pt_BR/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -308,4 +308,26 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "Enviar"; -?> + +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + +?> \ No newline at end of file Modified: trunk/i18n/pt_PT/main.php =================================================================== --- trunk/i18n/pt_PT/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/pt_PT/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -307,4 +307,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/ru_RU/main.php =================================================================== --- trunk/i18n/ru_RU/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/ru_RU/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -310,4 +310,26 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "Послать"; -?> + +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + +?> \ No newline at end of file Modified: trunk/i18n/sr_CS/main.php =================================================================== --- trunk/i18n/sr_CS/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/sr_CS/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -309,4 +309,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/sv_SE/main.php =================================================================== --- trunk/i18n/sv_SE/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/sv_SE/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -310,4 +310,29 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = "Skicka"; -?> + +// line 302 in pfcglobalconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be a charatere string"] = ""; + +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + +?> \ No newline at end of file Modified: trunk/i18n/tr_TR/main.php =================================================================== --- trunk/i18n/tr_TR/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/tr_TR/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -305,4 +305,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/uk_UA/main.php =================================================================== --- trunk/i18n/uk_UA/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/uk_UA/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -306,4 +306,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/zh_CN/main.php =================================================================== --- trunk/i18n/zh_CN/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/zh_CN/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -310,4 +310,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/i18n/zh_TW/main.php =================================================================== --- trunk/i18n/zh_TW/main.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/i18n/zh_TW/main.php 2006-12-08 13:55:33 UTC (rev 894) @@ -306,4 +306,25 @@ // line 88 in chat.js.tpl.php $GLOBALS["i18n"]["Send"] = ""; +// line 86 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: connect error"] = ""; + +// line 101 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create database error '%s'"] = ""; + +// line 112 in mysql.class.php +$GLOBALS["i18n"]["Mysql container: create table error '%s'"] = ""; + +// line 80 in chat.js.tpl.php +$GLOBALS["i18n"]["You are not allowed to speak to yourself"] = ""; + +// line 82 in chat.js.tpl.php +$GLOBALS["i18n"]["Choosen nickname is not allowed"] = ""; + +// line 83 in chat.js.tpl.php +$GLOBALS["i18n"]["Enable sound notifications"] = ""; + +// line 84 in chat.js.tpl.php +$GLOBALS["i18n"]["Disable sound notifications"] = ""; + ?> \ No newline at end of file Modified: trunk/src/client/chat.js.tpl.php =================================================================== --- trunk/src/client/chat.js.tpl.php 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/src/client/chat.js.tpl.php 2006-12-08 13:55:33 UTC (rev 894) @@ -80,8 +80,8 @@ "You are not allowed to speak to yourself", // _pfc "Close", // _pfc "Choosen nickname is not allowed", // _pfc - "Play sound", // _pfc - "Mute sound", // _pfc + "Enable sound notifications", // _pfc + "Disable sound notifications", // _pfc ); foreach($labels_to_load as $l) { Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-12-08 13:45:26 UTC (rev 893) +++ trunk/src/client/pfcclient.js 2006-12-08 13:55:33 UTC (rev 894) @@ -1434,13 +1434,13 @@ if (this.issoundenable) { snd_icon.src = this.res.getFileUrl('images/sound-on.gif'); - snd_icon.alt = this.res.getLabel('Mute sound'); + snd_icon.alt = this.res.getLabel('Disable sound notifications'); snd_icon.title = snd_icon.alt; } else { snd_icon.src = this.res.getFileUrl('images/sound-off.gif'); - snd_icon.alt = this.res.getLabel('Play sound'); + snd_icon.alt = this.res.getLabel('Enable sound notifications'); snd_icon.title = snd_icon.alt; } }, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-08 13:45:27
|
Revision: 893 http://svn.sourceforge.net/phpfreechat/?rev=893&view=rev Author: kerphi Date: 2006-12-08 05:45:26 -0800 (Fri, 08 Dec 2006) Log Message: ----------- remove annoying blinking when the sound notifier is started Modified Paths: -------------- trunk/src/client/pfcgui.js trunk/themes/default/style.css Modified: trunk/src/client/pfcgui.js =================================================================== --- trunk/src/client/pfcgui.js 2006-12-07 17:55:46 UTC (rev 892) +++ trunk/src/client/pfcgui.js 2006-12-08 13:45:26 UTC (rev 893) @@ -306,10 +306,10 @@ var soundcontainer = document.getElementById('pfc_sound_container'); if (pfc.issoundenable) { - var flash = '<object style="visibility:hidden" classid="clsid:D27CDB6E-AE6D-11CF-96B8-444553540000" id="obj1" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" border="0">'; + var flash = '<object style="visibility:hidden" classid="clsid:D27CDB6E-AE6D-11CF-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" width="0" height="0">'; flash += '<param name="movie" value="' + pfc.res.getFileUrl('sound.swf') + '">'; flash += '<param name="quality" value="High">'; - flash += '<embed src="' + pfc.res.getFileUrl('sound.swf') + '" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" name="obj1">'; + flash += '<embed style="visibility:hidden" src="' + pfc.res.getFileUrl('sound.swf') + '" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="0" height="0" />'; flash += '</object>'; soundcontainer.innerHTML = flash; } @@ -709,7 +709,7 @@ // sound container box : <div id="pfc_sound_container"> var soundcontainerbox = document.createElement('div'); soundcontainerbox.setAttribute('id', 'pfc_sound_container'); - inputcontainer.appendChild(soundcontainerbox); + container.appendChild(soundcontainerbox); } }; Modified: trunk/themes/default/style.css =================================================================== --- trunk/themes/default/style.css 2006-12-07 17:55:46 UTC (rev 892) +++ trunk/themes/default/style.css 2006-12-08 13:45:26 UTC (rev 893) @@ -348,7 +348,10 @@ font-size: 11px; } div#pfc_sound_container { + position: absolute; + top: 0; + left: 0; visibility:hidden; /* this box is hidden because it contains a flash sound media (sound.swf)*/ width: 0; height: 0; -} \ 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-12-07 17:56:02
|
Revision: 892 http://svn.sourceforge.net/phpfreechat/?rev=892&view=rev Author: kerphi Date: 2006-12-07 09:55:46 -0800 (Thu, 07 Dec 2006) Log Message: ----------- integrate the new command parsing function http://www.phpfreechat.net/forum/viewtopic.php?id=872 Modified Paths: -------------- trunk/src/pfccommand.class.php trunk/src/phpfreechat.class.php Added Paths: ----------- trunk/testcase/parsecommand.php Modified: trunk/src/pfccommand.class.php =================================================================== --- trunk/src/pfccommand.class.php 2006-12-07 14:38:34 UTC (rev 891) +++ trunk/src/pfccommand.class.php 2006-12-07 17:55:46 UTC (rev 892) @@ -190,7 +190,50 @@ $xml_reponse->addScript("trace('".$msg."');"); } + + function ParseCommand($cmd_str) + { + $pattern_quote = '/([^\\\]|^)"([^"]+[^\\\])"/'; + $pattern_quote = '/"([^"]+)"/'; + $pattern_noquote = '/([^"\s]+)/'; + $pattern_command = '/^\/([a-z0-9]+)\s*(.*)/'; + $result = array(); + // parse the command name (ex: '/invite') + if (preg_match($pattern_command, $cmd_str, $res)) + { + $cmd = $res[1]; + $params_str = $res[2]; + // parse the quotted parameters (ex: '/invite "nickname with spaces"') + preg_match_all($pattern_quote,$params_str,$res1,PREG_OFFSET_CAPTURE); + $params_res = $res1[1]; + // split the parameters string + $nospaces = preg_split($pattern_quote,$params_str,-1,PREG_SPLIT_OFFSET_CAPTURE|PREG_SPLIT_NO_EMPTY); + foreach($nospaces as $p) + { + // parse the splited blocks with unquotted parameter pattern (ex: '/invite nicknamewithoutspace') + preg_match_all($pattern_noquote,$p[0],$res2,PREG_OFFSET_CAPTURE); + foreach( $res2[1] as $p2 ) + { + $p2[1] += $p[1]; + $params_res[] = $p2; + } + } + + // order the array by offset + $params = array(); + foreach($params_res as $p) $params[$p[1]] = $p[0]; + ksort($params); + $params = array_values($params); + $params = array_map("trim",$params); + + $result['cmdstr'] = $cmd_str; + $result['cmdname'] = $cmd; + $result['params'] = $params; + } + return $result; + } + } -?> +?> \ No newline at end of file Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-12-07 14:38:34 UTC (rev 891) +++ trunk/src/phpfreechat.class.php 2006-12-07 17:55:46 UTC (rev 892) @@ -321,37 +321,28 @@ $u =& pfcUserConfig::Instance(); if ($c->debug) ob_start(); // capture output - + $xml_reponse = new xajaxResponse(); // check the command - $rawcmd = ""; - $clientid = ""; + $cmdstr = ""; + $cmdname = ""; + $clientid = ""; $recipient = ""; $recipientid = ""; - $param = ""; - $sender = ""; - //if (preg_match("/^\/([a-z]*) ([0-9a-f]*) ([0-9a-f]*)( (.*)|)/", $request, $res)) - //if (preg_match("/^\/([a-z]+) ([0-9a-f]+) ([0-9a-f]+) (.*)/", $request, $res)) - if (preg_match("/^\/([a-zA-Z0-9]+) ([0-9a-f]+) ([0-9a-f]+)( (.*)|)/", $request, $res)) - { - - $rawcmd = strtolower(isset($res[1]) ? $res[1] : ""); - $clientid = isset($res[2]) ? $res[2] : ""; - $recipientid = isset($res[3]) ? $res[3] : ""; - $param = isset($res[5]) ? $res[5] : ""; - $sender = $u->nick; - // $recipient = "home"; + $param = ""; + $sender = ""; - //if ($rawcmd == "join") - // trigger_error(var_export($res)); - - } - - //if ($rawcmd == "join") - //trigger_error("channels=".var_export($u->channels)); - //trigger_error("pvs=".var_export($u->privmsg)); + $res = pfcCommand::ParseCommand($request); + $cmdstr = isset($res['cmdstr']) ? $res['cmdstr'] : $request; + $cmdname = strtolower(isset($res['cmdname']) ? $res['cmdname'] : ''); + $clientid = isset($res['params'][0]) ? $res['params'][0] : ''; + $recipientid = isset($res['params'][1]) ? $res['params'][1] : ""; + $params = array_slice($res['params'],2); + $param = implode(" ",$params); // to keep compatibility (will be removed) + $sender = $u->nick; + // translate the recipientid to the channel name if (isset($u->channels[$recipientid])) { @@ -363,10 +354,10 @@ // @todo: move this code in a proxy - if ($rawcmd != "update" && - $rawcmd != "leave" && // do not open the pv tab when other user close the tab - $rawcmd != "quit" && - $rawcmd != "privmsg2") + if ($cmdname != "update" && + $cmdname != "leave" && // do not open the pv tab when other user close the tab + $cmdname != "quit" && + $cmdname != "privmsg2") { // alert the other from the new pv // (warn other user that someone talk to him) @@ -435,10 +426,11 @@ } - $cmd =& pfcCommand::Factory($rawcmd); + $cmd =& pfcCommand::Factory($cmdname); $cmdp = array(); $cmdp["clientid"] = $clientid; $cmdp["param"] = $param; + $cmdp["params"] = $params; $cmdp["sender"] = $sender; $cmdp["recipient"] = $recipient; $cmdp["recipientid"] = $recipientid; @@ -455,7 +447,7 @@ $cmd =& pfcCommand::Factory("error"); $cmdp = array(); $cmdp["clientid"] = $clientid; - $cmdp["param"] = _pfc("Unknown command [%s]",stripslashes("/".$rawcmd." ".$param)); + $cmdp["param"] = _pfc("Unknown command [%s]",stripslashes("/".$cmdname." ".$param)); $cmdp["sender"] = $sender; $cmdp["recipient"] = $recipient; $cmdp["recipientid"] = $recipientid; @@ -467,8 +459,8 @@ // do not update twice // do not update when the user just quit - if ($rawcmd != "update" && - $rawcmd != "quit" && + if ($cmdname != "update" && + $cmdname != "quit" && (!isset($u->nick) || $u->nick != "")) { // force an update just after a command is sent Added: trunk/testcase/parsecommand.php =================================================================== --- trunk/testcase/parsecommand.php (rev 0) +++ trunk/testcase/parsecommand.php 2006-12-07 17:55:46 UTC (rev 892) @@ -0,0 +1,51 @@ +<?php + +require_once dirname(__FILE__).'/../src/pfccommand.class.php'; + +$results = array(); +$results[] = array('cmdstr' => '/cmdname', + 'cmdname' => 'cmdname', + 'params' => array()); +$results[] = array('cmdstr' => '/cmdname "param1" "param2"', + 'cmdname' => 'cmdname', + 'params' => array('param1','param2')); +$results[] = array('cmdstr' => '/cmdname "param1" "param2" "param3"', + 'cmdname' => 'cmdname', + 'params' => array('param1','param2','param3')); +$results[] = array('cmdstr' => '/cmdname "param1 with spaces" "param2 with spaces"', + 'cmdname' => 'cmdname', + 'params' => array('param1 with spaces','param2 with spaces')); +$results[] = array('cmdstr' => '/cmdname000 "param1" "param2"', + 'cmdname' => 'cmdname000', + 'params' => array('param1','param2')); +$results[] = array('cmdstr' => '/cmdname param1 param2', + 'cmdname' => 'cmdname', + 'params' => array('param1','param2')); +$results[] = array('cmdstr' => '/cmdname "param1 with spaces" param2 param3', + 'cmdname' => 'cmdname', + 'params' => array('param1 with spaces','param2','param3')); +$results[] = array('cmdstr' => '/cmdname "param1" param2 "param3 with spaces" param4', + 'cmdname' => 'cmdname', + 'params' => array('param1', 'param2', 'param3 with spaces', 'param4')); +$results[] = array('cmdstr' => '/cmdname "param1""param2"', + 'cmdname' => 'cmdname', + 'params' => array('param1', 'param2')); +$results[] = array('cmdstr' => '/cmdname "param1withoutspace"', + 'cmdname' => 'cmdname', + 'params' => array('param1withoutspace')); +echo '<pre>'; +for($i = 0; $i<count($results); $i++) +{ + $command = $results[$i]['cmdstr']; + $result = pfcCommand::ParseCommand($command); + if ($result == $results[$i]) + echo "OK => $command\n"; + else + { + print_r($result); + echo "KO => $command\n"; + } +} +echo '</pre>'; + +?> \ 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-12-07 14:48:43
|
Revision: 891 http://svn.sourceforge.net/phpfreechat/?rev=891&view=rev Author: kerphi Date: 2006-12-07 06:38:34 -0800 (Thu, 07 Dec 2006) Log Message: ----------- bug fix: the max_displayed_lines feature was broken because the tab id was ignored so messages could disapear in other tabs. Modified Paths: -------------- trunk/src/client/pfcclient.js Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-12-06 22:45:30 UTC (rev 890) +++ trunk/src/client/pfcclient.js 2006-12-07 14:38:34 UTC (rev 891) @@ -776,7 +776,7 @@ handleComingRequest: function( cmds ) { var msg_html = $H(); - var max_msgid = 0; + var max_msgid = $H(); //alert(cmds.inspect()); @@ -795,7 +795,7 @@ // format and post message var line = ''; - line += '<div id="pfc_msg'+ id +'" class="pfc_cmd_'+ cmd +' pfc_message'; + line += '<div id="pfc_msg_'+recipientid+'_'+id+'" class="pfc_cmd_'+ cmd +' pfc_message'; line += (id % 2 == 0) ? ' pfc_evenmsg' : ' pfc_oddmsg'; if (oldmsg == 1) line += ' pfc_oldmsg'; line += '">'; @@ -840,7 +840,8 @@ msg_html[recipientid] += line; // remember the max message id in order to clean old lines - if (max_msgid < id) max_msgid = id; + if (!max_msgid[recipientid]) max_msgid[recipientid] = 0; + if (max_msgid[recipientid] < id) max_msgid[recipientid] = id; } // loop on all recipients and post messages @@ -861,22 +862,23 @@ // finaly append this to the message list recipientdiv.appendChild(m); this.gui.scrollDown(tabid, m); + + // delete the old messages from the client (save some memory) + var limit_msgid = max_msgid[recipientid] - pfc_max_displayed_lines; + var elt = $('pfc_msg_'+recipientid+'_'+limit_msgid); + while (elt) + { + // delete this element to save browser memory + if (is_ff) + elt.innerHTML = ''; + else + // this code don't work in FF, why ? don't know .. + elt.parentElement.removeChild(elt); + limit_msgid--; + elt = $('pfc_msg_'+recipientid+'_'+limit_msgid); + } } - // delete the old messages from the client (save some memory) - var limit_msgid = max_msgid - pfc_max_displayed_lines; - var elt = $('pfc_msg'+limit_msgid); - while (elt) - { - // delete this element to save browser memory - if (is_ff) - elt.innerHTML = ''; - else - // this code don't work in FF, why ? don't know .. - elt.parentElement.removeChild(elt); - limit_msgid--; - elt = $('pfc_msg'+limit_msgid); - } }, /** This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-06 23:38:55
|
Revision: 890 http://svn.sourceforge.net/phpfreechat/?rev=890&view=rev Author: kerphi Date: 2006-12-06 14:45:30 -0800 (Wed, 06 Dec 2006) Log Message: ----------- 1.0-beta8-pre Modified Paths: -------------- trunk/version Modified: trunk/version =================================================================== --- trunk/version 2006-12-06 15:44:39 UTC (rev 889) +++ trunk/version 2006-12-06 22:45:30 UTC (rev 890) @@ -1 +1 @@ -1.0-beta7 \ No newline at end of file +1.0-beta8-pre This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-06 15:44:43
|
Revision: 889 http://svn.sourceforge.net/phpfreechat/?rev=889&view=rev Author: kerphi Date: 2006-12-06 07:44:39 -0800 (Wed, 06 Dec 2006) Log Message: ----------- ajust demo server parameters Modified Paths: -------------- trunk/demo/demo55_mysql_container.php Modified: trunk/demo/demo55_mysql_container.php =================================================================== --- trunk/demo/demo55_mysql_container.php 2006-12-06 15:35:25 UTC (rev 888) +++ trunk/demo/demo55_mysql_container.php 2006-12-06 15:44:39 UTC (rev 889) @@ -4,12 +4,12 @@ $params["serverid"] = md5(__FILE__); // calculate a unique id for this chat $params["nick"] = "guest".rand(1,1000); $params["container_type"] = "mysql"; -$params["container_cfg_mysql_host"] = "localhost"; // this is the default value -$params["container_cfg_mysql_port"] = 3306; // this is the default value -$params["container_cfg_mysql_database"] = "phpfreechat"; // this is the default value -$params["container_cfg_mysql_table"] = "phpfreechat"; // this is the default value -$params["container_cfg_mysql_username"] = "root"; // this is the default value -$params["container_cfg_mysql_password"] = ""; // this is the default value +$params["container_cfg_mysql_host"] = "localhost"; // default value is "localhost" +$params["container_cfg_mysql_port"] = 3306; // default value is 3306 +$params["container_cfg_mysql_database"] = "phpfreechat"; // default value is "phpfreechat" +$params["container_cfg_mysql_table"] = "chat"; // default value is "phpfreechat" +$params["container_cfg_mysql_username"] = "phpfreechat"; // default value is "root" +$params["container_cfg_mysql_password"] = "yX7TZbZMUyZnXp6U"; // default value is "" $chat = new phpFreeChat($params); ?> @@ -38,4 +38,4 @@ ?> </body> -</html> \ No newline at end of file +</html> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-06 15:35:38
|
Revision: 888 http://svn.sourceforge.net/phpfreechat/?rev=888&view=rev Author: kerphi Date: 2006-12-06 07:35:25 -0800 (Wed, 06 Dec 2006) Log Message: ----------- [en] Add a mysql container. See demo55 for an example (thanks to HenkBB) [3h30] [fr] Ajout d'un conteneur mysql. Voyez la demo55 pour un exemple (merci ?\195?\160 HenkBB) [3h30] Modified Paths: -------------- trunk/demo/index.php trunk/testcase/container_generic.php Added Paths: ----------- trunk/demo/demo55_mysql_container.php trunk/src/containers/mysql.class.php trunk/testcase/container_mysql.php Added: trunk/demo/demo55_mysql_container.php =================================================================== --- trunk/demo/demo55_mysql_container.php (rev 0) +++ trunk/demo/demo55_mysql_container.php 2006-12-06 15:35:25 UTC (rev 888) @@ -0,0 +1,41 @@ +<?php + +require_once dirname(__FILE__)."/../src/phpfreechat.class.php"; +$params["serverid"] = md5(__FILE__); // calculate a unique id for this chat +$params["nick"] = "guest".rand(1,1000); +$params["container_type"] = "mysql"; +$params["container_cfg_mysql_host"] = "localhost"; // this is the default value +$params["container_cfg_mysql_port"] = 3306; // this is the default value +$params["container_cfg_mysql_database"] = "phpfreechat"; // this is the default value +$params["container_cfg_mysql_table"] = "phpfreechat"; // this is the default value +$params["container_cfg_mysql_username"] = "root"; // this is the default value +$params["container_cfg_mysql_password"] = ""; // this is the default value +$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> + <meta http-equiv="content-type" content="text/html; charset=utf-8" /> + <title>phpFreeChat demo</title> + <?php $chat->printJavascript(); ?> + <?php $chat->printStyle(); ?> + </head> + + <body> + <?php $chat->printChat(); ?> + +<?php + // print the current file + echo "<h2>The source code</h2>"; + $filename = __FILE__; + echo "<p><code>".$filename."</code></p>"; + echo "<pre style=\"margin: 0 50px 0 50px; padding: 10px; background-color: #DDD;\">"; + $content = file_get_contents($filename); + echo htmlentities($content); + echo "</pre>"; +?> + </body> + +</html> \ No newline at end of file Modified: trunk/demo/index.php =================================================================== --- trunk/demo/index.php 2006-12-04 17:12:10 UTC (rev 887) +++ trunk/demo/index.php 2006-12-06 15:35:25 UTC (rev 888) @@ -71,10 +71,10 @@ <li><a href="demo31_show_who_is_online-whoisonline.php">demo31 - demo which show how to get the connected users list (whoisonline script)</a></li> <li><a href="demo32_show_last_messages-chat.php">demo32 - demo which show how to get the last posted messages (chat script)</a></li> <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></li> <li><a href="demo50_customized_usermetadata.php">demo50 - demo which shows how to use user metadata : add avatar (images) to each connected users</a></li> + <li><a href="demo55_mysql_container.php">demo55 - demo which show how to use the mysql container</a></li> </ul> Added: trunk/src/containers/mysql.class.php =================================================================== --- trunk/src/containers/mysql.class.php (rev 0) +++ trunk/src/containers/mysql.class.php 2006-12-06 15:35:25 UTC (rev 888) @@ -0,0 +1,274 @@ +<?php +/** + * src/container/mysql.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__)."/../pfccontainer.class.php"; + +/** + * pfcContainer_Mysql is a concret container which store data into mysql + * + * Because of the new storage functions (setMeta, getMeta, rmMeta) + * everything can be stored in just one single table. + * Using type "HEAP" or "MEMORY" mysql loads this table into memory making it very fast + * There is no routine to create the table if it does not exists so you have to create it by hand + * Replace the database login info at the top of pfcContainer_mysql class with your own + * You also need some config lines in your chat index file: + * $params["container_type"] = "mysql"; + * $params["container_cfg_mysql_host"] = "localhost"; + * $params["container_cfg_mysql_port"] = 3306; + * $params["container_cfg_mysql_database"] = "phpfreechat"; + * $params["container_cfg_mysql_table"] = "phpfreechat"; + * $params["container_cfg_mysql_username"] = "root"; + * $params["container_cfg_mysql_password"] = ""; + * + * @author Stephane Gully <ste...@gm...> + * @author HenkBB + */ +class pfcContainer_Mysql extends pfcContainer +{ + var $_db = null; + var $_sql_create_table = " + CREATE TABLE IF NOT EXISTS `%table%` ( + `server` varchar(256) NOT NULL default '', + `group` varchar(256) NOT NULL default '', + `subgroup` varchar(256) NOT NULL default '', + `leaf` varchar(256) NOT NULL default '', + `leafvalue` varchar(1024) NOT NULL, + `timestamp` int(11) NOT NULL default 0, + PRIMARY KEY (`server`,`group`,`subgroup`,`leaf`) +) ENGINE=MEMORY;"; + + function pfcContainer_Mysql(&$config) + { + pfcContainer::pfcContainer($config); + } + + function getDefaultConfig() + { + $c =& $this->c; + $cfg = pfcContainer::getDefaultConfig(); + $cfg["mysql_host"] = 'localhost'; + $cfg["mysql_port"] = 3306; + $cfg["mysql_database"] = 'phpfreechat'; + $cfg["mysql_table"] = 'phpfreechat'; + $cfg["mysql_username"] = 'root'; + $cfg["mysql_password"] = ''; + return $cfg; + } + + function init() + { + $errors = pfcContainer::init(); + $c =& $this->c; + + // connect to the db + $db = $this->_connect(); + if ($db === FALSE) + { + $errors[] = _pfc("Mysql container: connect error"); + return $errors; + } + + // create the db if it doesn't exists + $db_exists = false; + $db_list = mysql_list_dbs($db); + while (!$db_exists && $row = mysql_fetch_object($db_list)) + $db_exists = ($c->container_cfg_mysql_database == $row->Database); + if (!$db_exists) + { + $query = 'CREATE DATABASE '.$c->container_cfg_mysql_database; + $result = mysql_query($query, $db); + if ($result === FALSE) + { + $errors[] = _pfc("Mysql container: create database error '%s'",mysql_error($db)); + return $errors; + } + mysql_select_db($c->container_cfg_mysql_database, $db); + } + + // create the table if it doesn't exists + $query = str_replace('%table%',$c->container_cfg_mysql_table,$this->_sql_create_table); + $result = mysql_query($query, $db); + if ($result === FALSE) + { + $errors[] = _pfc("Mysql container: create table error '%s'",mysql_error($db)); + return $errors; + } + return $errors; + } + + function _connect() + { + if (!$this->_db) + { + $c =& $this->c; + $this->_db = mysql_pconnect($c->container_cfg_mysql_host.':'.$c->container_cfg_mysql_port, + $c->container_cfg_mysql_username, + $c->container_cfg_mysql_password); + mysql_select_db($c->container_cfg_mysql_database, $this->_db); + } + return $this->_db; + } + + function setMeta($group, $subgroup, $leaf, $leafvalue = NULL) + { + $c =& $this->c; + + if ($c->debug) + file_put_contents("/tmp/debug.txt", "\nsetMeta(".$group.",".$subgroup.",".$leaf.",".$leafvalue.")", FILE_APPEND); + + $server = $c->serverid; + $db = $this->_connect(); + + if ($leafvalue == NULL){$leafvalue="";}; + + $sql_select = "SELECT * FROM ".$c->container_cfg_mysql_table." WHERE `server`='$server' AND `group`='$group' AND `subgroup`='$subgroup' AND `leaf`='$leaf'"; + $sql_insert="REPLACE INTO ".$c->container_cfg_mysql_table." (`server`, `group`, `subgroup`, `leaf`, `leafvalue`, `timestamp`) VALUES('$server', '$group', '$subgroup', '$leaf', '".addslashes($leafvalue)."', '".time()."')"; + $sql_update="UPDATE ".$c->container_cfg_mysql_table." SET `leafvalue`='".addslashes($leafvalue)."', `timestamp`='".time()."' WHERE `server`='$server' AND `group`='$group' AND `subgroup`='$subgroup' AND `leaf`='$leaf'"; + + $res = mysql_query($sql_select, $db); + if( !(mysql_num_rows($res)>0) ) + { + if ($c->debug) + file_put_contents("/tmp/debug.txt", "\nsetSQL(".$sql_insert.")", FILE_APPEND); + + mysql_query($sql_insert, $db); + return 0; // value created + } + else + { + if ($sql_update != "") + { + if ($c->debug) + file_put_contents("/tmp/debug.txt", "\nsetSQL(".$sql_update.")", FILE_APPEND); + + mysql_query($sql_update, $db); + } + return 1; // value overwritten + } + } + + + function getMeta($group, $subgroup = null, $leaf = null, $withleafvalue = false) + { + $c =& $this->c; + if ($c->debug) + file_put_contents("/tmp/debug.txt", "\ngetMeta(".$group.",".$subgroup.",".$leaf.",".$withleafvalue.")", FILE_APPEND); + + $ret = array(); + $ret["timestamp"] = array(); + $ret["value"] = array(); + + $server = $c->serverid; + $db = $this->_connect(); + + $sql_where=""; + $value="leafvalue"; + + if ($group != NULL) + { + $sql_where.=" AND `group`='$group'"; + $value="subgroup"; + } + + if ($subgroup != NULL) + { + $sql_where.=" AND `subgroup`='$subgroup'"; + $value="leaf"; + } + + if ($leaf != NULL) + { + $sql_where.=" AND `leaf`='$leaf'"; + $value="leafvalue"; + } + + $sql_select="SELECT `$value`, `timestamp` FROM ".$c->container_cfg_mysql_table." WHERE `server`='$server' $sql_where GROUP BY `$value` ORDER BY timestamp"; + + if ($c->debug) + file_put_contents("/tmp/debug.txt", "\ngetSQL(".$sql_select.")", FILE_APPEND); + + if ($sql_select != "") + { + $thisresult = mysql_query($sql_select, $db); + if (mysql_num_rows($thisresult)) + { + while ($regel = mysql_fetch_array($thisresult)) + { + $ret["timestamp"][] = $regel["timestamp"]; + if ($value == "leafvalue") + { + if ($withleafvalue) + $ret["value"][] = $regel[$value]; + else + $ret["value"][] = NULL; + } + else + $ret["value"][] = $regel[$value]; + } + + } + else + return $ret; + } + return $ret; + } + + function rmMeta($group, $subgroup = null, $leaf = null) + { + $c =& $this->c; + if ($c->debug) + file_put_contents("/tmp/debug.txt", "\nrmMeta(".$group.",".$subgroup.",".$leaf.")", FILE_APPEND); + + $server = $c->serverid; + $db = $this->_connect(); + + $sql_delete = "DELETE FROM ".$c->container_cfg_mysql_table." WHERE `server`='$server'"; + + if($group != NULL) + $sql_delete .= " AND `group`='$group'"; + + if($subgroup != NULL) + $sql_delete .= " AND `subgroup`='$subgroup'"; + + if ($leaf != NULL) + $sql_delete .= " AND `leaf`='$leaf'"; + + if ($c->debug) + file_put_contents("/tmp/debug.txt", "\nrmSQL(".$sql_delete.")", FILE_APPEND); + + mysql_query($sql_delete, $db); + return true; + } + + function encode($str) + { + return addslashes(urlencode($str)); + } + + function decode($str) + { + return urldecode(stripslashes($str)); + } + +} + +?> \ No newline at end of file Modified: trunk/testcase/container_generic.php =================================================================== --- trunk/testcase/container_generic.php 2006-12-04 17:12:10 UTC (rev 887) +++ trunk/testcase/container_generic.php 2006-12-06 15:35:25 UTC (rev 888) @@ -31,7 +31,7 @@ require_once dirname(__FILE__)."/../src/pfcglobalconfig.class.php"; $params = array(); $params["title"] = "testcase -> pfccontainer_".$this->type; - $params["serverid"] = md5(__FILE__/* . time()*/); + $params["serverid"] = md5(__FILE__ . time()); $params["container_type"] = $this->type; $this->c = new pfcGlobalConfig($params); $this->ct = $this->c->getContainerInstance(); @@ -296,7 +296,7 @@ $ret = $ct->getMeta($group, $subgroup, $leaf, true); $this->assertEquals($ret['value'][0], $leafvalue, "the leaf value is wrong"); } - + function test_getMeta_Generic_1() { $c =& $this->c; @@ -344,7 +344,7 @@ $time = time(); $ret = $ct->getMeta($group, $subgroup); - asort($ret["value"]); + sort($ret["value"]); $this->assertEquals(count($ret["timestamp"]), 2, "number of leaf is wrong"); $this->assertEquals($ret["timestamp"][0], $time, "the leaf timestamp is wrong"); $this->assertEquals($ret["timestamp"][1], $time, "the leaf timestamp is wrong"); @@ -368,16 +368,15 @@ $ct->setMeta($group, $subgroup2, $leaf1); $ct->setMeta($group, $subgroup2, $leaf2); $time = time(); - + $ret = $ct->getMeta($group); - asort($ret["value"]); - $this->assertEquals(count($ret["timestamp"]), 2, "number of subgroup is wrong"); - $this->assertEquals($ret["timestamp"][0], $time, "the subgroup timestamp is wrong"); - $this->assertEquals($ret["timestamp"][1], $time, "the subgroup timestamp is wrong"); - $this->assertEquals($ret["value"][0], $subgroup1, "the subgroup name is wrong"); - $this->assertEquals($ret["value"][1], $subgroup2, "the subgroup name is wrong"); + sort($ret["value"]); + $this->assertEquals(2, count($ret["timestamp"]), "number of subgroup is wrong"); + $this->assertEquals($time, $ret["timestamp"][0], "the subgroup timestamp is wrong"); + $this->assertEquals($time, $ret["timestamp"][1], "the subgroup timestamp is wrong"); + $this->assertEquals($subgroup1, $ret["value"][0], "the subgroup name is wrong"); + $this->assertEquals($subgroup2, $ret["value"][1], "the subgroup name is wrong"); } - } ?> Added: trunk/testcase/container_mysql.php =================================================================== --- trunk/testcase/container_mysql.php (rev 0) +++ trunk/testcase/container_mysql.php 2006-12-06 15:35:25 UTC (rev 888) @@ -0,0 +1,41 @@ +<?php + +require_once "container_generic.php"; + +class pfcContainerTestcase_Mysql extends pfcContainerTestcase +{ + // constructor of the test suite + function pfcContainerTestcase_Mysql($name) + { + $this->type = "Mysql"; + $this->pfcContainerTestcase($name); + } + + // called before the test functions will be executed + // this function is defined in PHPUnit_TestCase and overwritten + // here + function setUp() + { + pfcContainerTestcase::setUp(); + } + + // called after the test functions are executed + // this function is defined in PHPUnit_TestCase and overwritten + // here + function tearDown() + { + pfcContainerTestcase::tearDown(); + } +} + +// on desactive le timeout car se script peut mettre bcp de temps a s'executer +ini_set('max_execution_time', 0); + +$suite = new PHPUnit_TestSuite(); +$suite->addTestSuite("pfcContainerTestcase_Mysql"); +$result =& PHPUnit::run($suite); +echo "<pre>"; +print_r($result->toString()); +echo "</pre>"; + +?> \ 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-12-04 17:12:19
|
Revision: 887 http://svn.sourceforge.net/phpfreechat/?rev=887&view=rev Author: kerphi Date: 2006-12-04 09:12:10 -0800 (Mon, 04 Dec 2006) Log Message: ----------- [en] New parameter 'max_displayed_lines' (by default 150) used to free browser's memory when lot of lines are written in the chat. [1h20] [fr] Nouveau param?\195?\168tre 'max_displayed_lines' (par d?\195?\169faut 150) permettant de lib?\195?\169rer la m?\195?\169moire du navigateur lorsque bcp de messages sont affich?\195?\169s. [1h20] Modified Paths: -------------- trunk/src/client/chat.js.tpl.php trunk/src/client/pfcclient.js trunk/src/pfcglobalconfig.class.php Modified: trunk/src/client/chat.js.tpl.php =================================================================== --- trunk/src/client/chat.js.tpl.php 2006-12-02 17:22:18 UTC (rev 886) +++ trunk/src/client/chat.js.tpl.php 2006-12-04 17:12:10 UTC (rev 887) @@ -19,6 +19,7 @@ var pfc_showwhosonline = <?php echo $json->encode($showwhosonline); ?>; var pfc_focus_on_connect = <?php echo $json->encode($focus_on_connect); ?>; var pfc_max_text_len = <?php echo $json->encode($max_text_len); ?>; +var pfc_max_displayed_lines = <?php echo $json->encode($max_displayed_lines); ?>; var pfc_quit_on_closedwindow = <?php echo $json->encode($quit_on_closedwindow); ?>; var pfc_debug = <?php echo $json->encode($debug); ?>; var pfc_btn_sh_smileys = <?php echo $json->encode($btn_sh_smileys); ?>; Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-12-02 17:22:18 UTC (rev 886) +++ trunk/src/client/pfcclient.js 2006-12-04 17:12:10 UTC (rev 887) @@ -776,6 +776,7 @@ handleComingRequest: function( cmds ) { var msg_html = $H(); + var max_msgid = 0; //alert(cmds.inspect()); @@ -804,20 +805,20 @@ line += '<span class="pfc_heure">'+ time +'</span> '; if (cmd == 'send') { - line += ' <span class="pfc_nick">'; - line += '‹'; - line += '<span '; + line += ' <span class="pfc_nick">'; + line += '‹'; + line += '<span '; line += 'onclick="pfc.insert_text(\'' + sender.replace("'", '\\\'') + ', \',\'\',false)" '; - line += 'class="pfc_nickmarker pfc_nick_'+ hex_md5(_to_utf8(sender)) +'">'; - line += sender; - line += '</span>'; - line += '›'; - line += '</span> '; + line += 'class="pfc_nickmarker pfc_nick_'+ hex_md5(_to_utf8(sender)) +'">'; + line += sender; + line += '</span>'; + line += '›'; + line += '</span> '; } if (cmd == 'notice' || cmd == 'me') - line += '<span class="pfc_words">* '+ this.parseMessage(param) +'</span> '; + line += '<span class="pfc_words">* '+ this.parseMessage(param) +'</span> '; else - line += '<span class="pfc_words">'+ this.parseMessage(param) +'</span> '; + line += '<span class="pfc_words">'+ this.parseMessage(param) +'</span> '; line += '</div>'; if (oldmsg == 0) @@ -828,7 +829,7 @@ var tabid = recipientid; if (this.gui.getTabId() != tabid) this.gui.notifyTab(tabid); - // notify the window (change the title) + // notify the window (change the title) if (!this.detectactivity.isActive() && pfc_notify_window) this.gui.notifyWindow(); } @@ -837,6 +838,9 @@ msg_html[recipientid] = line; else msg_html[recipientid] += line; + + // remember the max message id in order to clean old lines + if (max_msgid < id) max_msgid = id; } // loop on all recipients and post messages @@ -858,6 +862,21 @@ recipientdiv.appendChild(m); this.gui.scrollDown(tabid, m); } + + // delete the old messages from the client (save some memory) + var limit_msgid = max_msgid - pfc_max_displayed_lines; + var elt = $('pfc_msg'+limit_msgid); + while (elt) + { + // delete this element to save browser memory + if (is_ff) + elt.innerHTML = ''; + else + // this code don't work in FF, why ? don't know .. + elt.parentElement.removeChild(elt); + limit_msgid--; + elt = $('pfc_msg'+limit_msgid); + } }, /** Modified: trunk/src/pfcglobalconfig.class.php =================================================================== --- trunk/src/pfcglobalconfig.class.php 2006-12-02 17:22:18 UTC (rev 886) +++ trunk/src/pfcglobalconfig.class.php 2006-12-04 17:12:10 UTC (rev 887) @@ -72,7 +72,8 @@ var $refresh_delay = 5000; // in mili-seconds (5 seconds) var $max_refresh_delay = 60000; // in mili-seconds (60 seconds) var $timeout = 20000; // in mili-seconds (20 seconds) - var $max_msg = 20; + var $max_msg = 20; // number of messages keept in the history (this is what you see when you reload the chat) + var $max_displayed_lines = 150; // maximum number of displayed lines (old lines will be deleted to save browser's memory) var $quit_on_closedwindow = true; // could be annoying because the reload event is the same as a close event var $focus_on_connect = true; var $connect_at_startup = true; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-02 17:22:22
|
Revision: 886 http://svn.sourceforge.net/phpfreechat/?rev=886&view=rev Author: kerphi Date: 2006-12-02 09:22:18 -0800 (Sat, 02 Dec 2006) Log Message: ----------- [en] German translation update : 'de_DE-informal' (thanks to karsten) [5min] [fr] Mise ?\195?\160 jour de la traduction allemande : 'de_DE-informal' (merci ?\195?\160 karsten) [5min] Modified Paths: -------------- trunk/i18n/de_DE-informal/main.php Modified: trunk/i18n/de_DE-informal/main.php =================================================================== --- trunk/i18n/de_DE-informal/main.php 2006-12-01 22:23:19 UTC (rev 885) +++ trunk/i18n/de_DE-informal/main.php 2006-12-02 17:22:18 UTC (rev 886) @@ -24,25 +24,26 @@ * German (informal) translation of the messages (utf8 encoded!) * * @author BSEMF <bsemfger <at> aim.com> + * @author Karsten Hens www.karsten-hens.de */ // line 45 in phpfreechatconfig.class.php $GLOBALS["i18n"]["My Chat"] = "Mein Chat"; // line 201 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["%s not found, %s library can't be found."] = "%s wurde nicht gefunden, %s Programmbibliothek konnte nicht gefunden werden."; +$GLOBALS["i18n"]["%s not found, %s library can't be found."] = "%s wurde nicht gefunden, die Programmbibliothek %s konnte nicht gefunden werden."; // line 355 in phpfreechat.class.php -$GLOBALS["i18n"]["Please enter your nickname"] = "Bitte gib deinen Nickname ein"; +$GLOBALS["i18n"]["Please enter your nickname"] = "Bitte gib deinen Nicknamen ein"; // line 565 in phpfreechat.class.php -$GLOBALS["i18n"]["Text cannot be empty"] = "Text darf nicht leer sein"; +$GLOBALS["i18n"]["Text cannot be empty"] = "Text darf nicht fehlen"; // line 392 in phpfreechat.class.php -$GLOBALS["i18n"]["%s changes his nickname to %s"] = "%s ändert seinen Nickname zu %s"; +$GLOBALS["i18n"]["%s changes his nickname to %s"] = "%s ändert seinen Nicknamen zu %s"; // line 398 in phpfreechat.class.php -$GLOBALS["i18n"]["%s is connected"] = "%s hat sich verbunden"; +$GLOBALS["i18n"]["%s is connected"] = "%s ist verbunden"; // line 452 in phpfreechat.class.php $GLOBALS["i18n"]["%s quit"] = "%s verließ den Chat"; @@ -57,16 +58,16 @@ $GLOBALS["i18n"]["%s doesn't exist: %s"] = "%s existiert nicht: %s"; // line 180 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["You need %s"] = "Du brauchst %s"; +$GLOBALS["i18n"]["You need %s"] = "Du benötigst %s"; // line 241 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["%s doesn't exist, %s library can't be found"] = "%s wurde nicht gefunden, %s Programmbibliothek konnte nicht gefunden werden"; +$GLOBALS["i18n"]["%s doesn't exist, %s library can't be found"] = "%s existiert nicht, die Programmbibliothek %s konnte nicht gefunden werden"; // line 280 in phpfreechatconfig.class.php $GLOBALS["i18n"]["%s doesn't exist"] = "%s existiert nicht"; // line 433 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["%s directory must be specified"] = "%s Verzeichniss muss angegeben werden"; +$GLOBALS["i18n"]["%s directory must be specified"] = "%s Verzeichnis muss angegeben werden"; // line 439 in phpfreechatconfig.class.php $GLOBALS["i18n"]["%s must be a directory"] = "%s muss ein Verzeichnis sein"; @@ -90,10 +91,10 @@ $GLOBALS["i18n"]["PHP FREE CHAT [powered by phpFreeChat-%s]"] = "PHP FREE CHAT [powered by phpFreeChat-%s]"; // line 296 in javascript1.js.tpl.php -$GLOBALS["i18n"]["Hide nickname marker"] = "Verstecke Nickname Farben"; +$GLOBALS["i18n"]["Hide nickname marker"] = "Farbmarkierung der Nicknamen abschalten"; // line 304 in javascript1.js.tpl.php -$GLOBALS["i18n"]["Show nickname marker"] = "Zeige Nickname Farben"; +$GLOBALS["i18n"]["Show nickname marker"] = "Farbmarkierung der Nicknamen einschalten"; // line 389 in javascript1.js.tpl.php $GLOBALS["i18n"]["Disconnect"] = "Verbindung beenden"; @@ -102,40 +103,40 @@ $GLOBALS["i18n"]["Connect"] = "Verbindung herstellen"; // line 427 in javascript1.js.tpl.php -$GLOBALS["i18n"]["Magnify"] = "Vergrößern"; +$GLOBALS["i18n"]["Magnify"] = "Fenster maximieren"; // line 434 in javascript1.js.tpl.php -$GLOBALS["i18n"]["Cut down"] = "Verkleinern"; +$GLOBALS["i18n"]["Cut down"] = "Fenster minimieren"; // line 345 in javascript1.js.tpl.php -$GLOBALS["i18n"]["Hide dates and hours"] = "Verstecke Datum und Zeit"; +$GLOBALS["i18n"]["Hide dates and hours"] = "Datum und Zeit ausblenden"; // line 353 in javascript1.js.tpl.php -$GLOBALS["i18n"]["Show dates and hours"] = "Zeige Datum und Zeit"; +$GLOBALS["i18n"]["Show dates and hours"] = "Datum und Zeit einblenden"; // line 21 in chat.html.tpl.php -$GLOBALS["i18n"]["Enter your message here"] = "Gib deine Nachricht hier ein"; +$GLOBALS["i18n"]["Enter your message here"] = "Gib hier deine Nachricht ein"; // line 24 in chat.html.tpl.php -$GLOBALS["i18n"]["Enter your nickname here"] = "Gib deinen Nickname hier ein"; +$GLOBALS["i18n"]["Enter your nickname here"] = "Gib hier deinen Nicknamen ein"; // line 93 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["Error: undefined or obsolete parameter '%s', please correct or remove this parameter"] = "Error: Undefinierter oder falscher Parameter '%s', bitte korrigiere oder lösche diesen Parameter"; +$GLOBALS["i18n"]["Error: undefined or obsolete parameter '%s', please correct or remove this parameter"] = "Fehler: Undefinierter oder obsoleter Parameter '%s', bitte korrigiere oder lösche diesen Parameter"; // line 48 in phpfreechattemplate.class.php $GLOBALS["i18n"]["%s template could not be found"] = "%s Template wurde nicht gefunden"; // line 324 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["'serverid' parameter is mandatory by default use 'md5(__FILE__)' value"] = "'serverid' Parameter is zwingend notwendig, nutze standartmäßig den Wert 'md5(__FILE__)'"; +$GLOBALS["i18n"]["'serverid' parameter is mandatory by default use 'md5(__FILE__)' value"] = "Der Parameter 'serverid' ist zwingend notwendig, standardmäßiger Wert: 'md5(__FILE__)'"; // line 512 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["Error: '%s' could not be found, please check your themepath '%s' and your theme '%s' are correct"] = "'%s' konnte nicht gefunden werden, bitte überprüfe den Themenpfad '%s' und das Thema '%s'"; +$GLOBALS["i18n"]["Error: '%s' could not be found, please check your themepath '%s' and your theme '%s' are correct"] = "Fehler: '%s' konnte nicht gefunden werden, bitte überprüfe den Pfad zu 'themes' '%s' und das Thema '%s'"; // line 33 in chat.html.tpl.php -$GLOBALS["i18n"]["Bold"] = "Fett"; +$GLOBALS["i18n"]["Bold"] = "fett"; // line 34 in chat.html.tpl.php -$GLOBALS["i18n"]["Italics"] = "Kursiv"; +$GLOBALS["i18n"]["Italics"] = "kursiv"; // line 35 in chat.html.tpl.php $GLOBALS["i18n"]["Underline"] = "unterstrichen"; @@ -147,166 +148,165 @@ $GLOBALS["i18n"]["Pre"] = "Pre"; // line 38 in chat.html.tpl.php -$GLOBALS["i18n"]["Mail"] = "eMail"; +$GLOBALS["i18n"]["Mail"] = "E-Mail"; // line 39 in chat.html.tpl.php $GLOBALS["i18n"]["Color"] = "Farbe"; // line 86 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Hide smiley box"] = "Smilie Box verstecken"; +$GLOBALS["i18n"]["Hide smiley box"] = "Smileybox ausblenden"; // line 87 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Show smiley box"] = "Smilie Box zeigen"; +$GLOBALS["i18n"]["Show smiley box"] = "Smileybox einblenden"; // line 88 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Hide online users box"] = "Online Nutzer Box verstecken"; +$GLOBALS["i18n"]["Hide online users box"] = "Liste der Online Benutzer verstecken"; // line 89 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Show online users box"] = "Online Nutzer Box zeigen"; +$GLOBALS["i18n"]["Show online users box"] = "Liste der Online Benutzer zeigen"; // line 75 in pfccommand.class.php $GLOBALS["i18n"]["%s must be implemented"] = "%s muss implementiert werden"; // line 343 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["'%s' parameter is mandatory by default use '%s' value"] = ""; +$GLOBALS["i18n"]["'%s' parameter is mandatory by default use '%s' value"] = "'%s' ist ein obligatorischer Parameter. Voreinstellungswert: '%s' "; // line 378 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["'%s' parameter must be a positive number"] = ""; +$GLOBALS["i18n"]["'%s' parameter must be a positive number"] = "Der Parameter '%s' muß eine natürliche Zahl sein"; // line 386 in phpfreechatconfig.class.php -$GLOBALS["i18n"]["'%s' parameter is not valid. Available values are : '%s'"] = ""; +$GLOBALS["i18n"]["'%s' parameter is not valid. Available values are : '%s'"] = "Der Parameter '%s' ist ungültig. Mögliche Werte sind '%s'"; // line 186 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["My room"] = ""; +$GLOBALS["i18n"]["My room"] = "Mein Chat"; // line 19 in unban.class.php -$GLOBALS["i18n"]["Missing parameter"] = ""; +$GLOBALS["i18n"]["Missing parameter"] = "Fehlende Parameter"; // line 38 in ban.class.php -$GLOBALS["i18n"]["banished from %s by %s"] = ""; +$GLOBALS["i18n"]["banished from %s by %s"] = "wurde gebannt von %s durch %s"; // line 23 in banlist.class.php -$GLOBALS["i18n"]["The banished user's id list is:"] = ""; +$GLOBALS["i18n"]["The banished user's id list is:"] = "Die Liste der gebannten Benutzer-IDs"; // line 32 in banlist.class.php -$GLOBALS["i18n"]["Empty"] = ""; +$GLOBALS["i18n"]["Empty"] = "leer"; // line 34 in banlist.class.php -$GLOBALS["i18n"]["'/unban {id}' will unban the user identified by {id}"] = ""; +$GLOBALS["i18n"]["'/unban {id}' will unban the user identified by {id}"] = "'/unban {id}' streicht den Benutzer mit der ID {id} von der Bannliste"; // line 35 in banlist.class.php -$GLOBALS["i18n"]["'/unban all' will unban all the users on this channel"] = ""; +$GLOBALS["i18n"]["'/unban all' will unban all the users on this channel"] = "'/unban all' hebt die Bannung aller Benutzer des Channels auf"; // line 24 in update.class.php -$GLOBALS["i18n"]["%s quit (timeout)"] = ""; +$GLOBALS["i18n"]["%s quit (timeout)"] = "%s verließ den Raum (timeout?)"; // line 46 in join.class.php -$GLOBALS["i18n"]["%s joins %s"] = ""; +$GLOBALS["i18n"]["%s joins %s"] = "%s kommt in den Channel %s"; // line 31 in kick.class.php -$GLOBALS["i18n"]["kicked from %s by %s"] = ""; +$GLOBALS["i18n"]["kicked from %s by %s"] = "wurde herausgeworfen aus %s von %s"; // line 38 in send.class.php -$GLOBALS["i18n"]["Can't send the message, %s is offline"] = ""; +$GLOBALS["i18n"]["Can't send the message, %s is offline"] = "Kann keine Nachricht senden, %s is offline"; // line 27 in unban.class.php -$GLOBALS["i18n"]["Nobody has been unbanished"] = ""; +$GLOBALS["i18n"]["Nobody has been unbanished"] = "Niemand wurde von der Bannliste gestrichen"; // line 42 in unban.class.php -$GLOBALS["i18n"]["%s has been unbanished"] = ""; +$GLOBALS["i18n"]["%s has been unbanished"] = "%s wurde von der Bannliste gestrichen"; // line 49 in unban.class.php -$GLOBALS["i18n"]["%s users have been unbanished"] = ""; +$GLOBALS["i18n"]["%s users have been unbanished"] = "%s Benutzer wurden von der Bannliste gestrichen"; // line 47 in auth.class.php -$GLOBALS["i18n"]["You are not allowed to run '%s' command"] = ""; +$GLOBALS["i18n"]["You are not allowed to run '%s' command"] = "Du hast keine Berechtigung zur Ausführung von '%s'"; // line 66 in auth.class.php -$GLOBALS["i18n"]["Can't join %s because you are banished"] = ""; +$GLOBALS["i18n"]["Can't join %s because you are banished"] = "Du kannst an %s nicht teilnehmen, weil du auf der Bannliste stehst"; // line 76 in auth.class.php -$GLOBALS["i18n"]["Can't join %s because the channels list is restricted"] = ""; +$GLOBALS["i18n"]["Can't join %s because the channels list is restricted"] = "Du kannst an %s nicht teilnehmen, weil der Zugang begrenzt wurde"; // line 89 in auth.class.php -$GLOBALS["i18n"]["You are not allowed to change your nickname"] = ""; +$GLOBALS["i18n"]["You are not allowed to change your nickname"] = "Du darfst deinen Nicknamen nicht ändern"; // line 56 in noflood.class.php -$GLOBALS["i18n"]["Please don't post so many message, flood is not tolerated"] = ""; +$GLOBALS["i18n"]["Please don't post so many message, flood is not tolerated"] = "Bitte überflute den Chatraum nicht mit so vielen Postings"; // line 109 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Private message"] = ""; +$GLOBALS["i18n"]["Private message"] = "Private Nachricht"; // line 110 in pfcclient.js.tpl.php -$GLOBALS["i18n"]["Close this tab"] = ""; +$GLOBALS["i18n"]["Close this tab"] = "Schließe diesen Reiter"; // line 199 in pfcgui.js.tpl.php -$GLOBALS["i18n"]["Do you really want to leave this room ?"] = ""; +$GLOBALS["i18n"]["Do you really want to leave this room ?"] = "Möchtest du wirklich den Raum verlassen?"; // line 169 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["Error: '%s' is a private parameter, you are not allowed to change it"] = ""; +$GLOBALS["i18n"]["Error: '%s' is a private parameter, you are not allowed to change it"] = "Fehler: '%s' ist ein geschützter Parameter, du darfst ihn nicht ändern"; // line 253 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' parameter must be an array"] = ""; +$GLOBALS["i18n"]["'%s' parameter must be an array"] = "Der Parameter '%s' muss ein Array sein"; // line 265 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' parameter must be a boolean"] = ""; +$GLOBALS["i18n"]["'%s' parameter must be a boolean"] = "Der Parameter '%s' muss ein Boolean sein"; // line 271 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' parameter must be a charatere string"] = ""; +$GLOBALS["i18n"]["'%s' parameter must be a charatere string"] = "Der Parameter '%s' muss eine Zeichenkette sein"; // line 395 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' must be writable"] = ""; +$GLOBALS["i18n"]["'%s' must be writable"] = "'%s' muß beschreibbar sein"; // line 425 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["'%s' directory doesn't exist"] = ""; +$GLOBALS["i18n"]["'%s' directory doesn't exist"] = "'%s' Verzeichnis existiert nicht"; // line 544 in pfcglobalconfig.class.php -$GLOBALS["i18n"]["Please correct these errors"] = ""; +$GLOBALS["i18n"]["Please correct these errors"] = "Bitte korrigiere diese Fehler"; // line 21 in pfcinfo.class.php -$GLOBALS["i18n"]["Error: the cached config file doesn't exists"] = ""; +$GLOBALS["i18n"]["Error: the cached config file doesn't exists"] = "Fehler: Die gesuchte Konfigurations-Datei existiert nicht im Cache"; // line 190 in phpfreechat.class.php -$GLOBALS["i18n"]["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"] = ""; +$GLOBALS["i18n"]["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"] = "Fehler: Der Chat kann nicht geladen werden! Es gibt zwei Möglichkeiten: dein Browser unterstützt kein JavaScript oder die Verzeichnisrechte auf dem Server sind nicht korrekt eingerichtet. Zögere nicht, im Forum nach Hilfe zu suchen"; // line 31 in help.class.php -$GLOBALS["i18n"]["Here is the command list:"] = ""; +$GLOBALS["i18n"]["Here is the command list:"] = "Hier ist die Liste möglicher Befehle:"; // line 63 in identify.class.php -$GLOBALS["i18n"]["Succesfully identified"] = ""; +$GLOBALS["i18n"]["Succesfully identified"] = "Identifizierung erfolgt"; // line 68 in identify.class.php -$GLOBALS["i18n"]["Identification failure"] = ""; +$GLOBALS["i18n"]["Identification failure"] = "Identifizierung fehlgeschlagen"; // line 25 in send.class.php -$GLOBALS["i18n"]["Your must be connected to send a message"] = ""; +$GLOBALS["i18n"]["Your must be connected to send a message"] = "Du musst verbunden sein, um eine Nachricht zu schicken"; // line 87 in chat.js.tpl.php -$GLOBALS["i18n"]["Click here to send your message"] = ""; +$GLOBALS["i18n"]["Click here to send your message"] = "Hier klicken, um die Nachricht zu senden"; // line 80 in chat.js.tpl.php -$GLOBALS["i18n"]["Enter the text to format"] = ""; +$GLOBALS["i18n"]["Enter the text to format"] = "Gib erst den Text ein, der formatiert werden soll"; // line 81 in chat.js.tpl.php -$GLOBALS["i18n"]["Configuration has been rehashed"] = ""; +$GLOBALS["i18n"]["Configuration has been rehashed"] = "Die Konfiguration wurde neu geladen"; // line 82 in chat.js.tpl.php -$GLOBALS["i18n"]["A problem occurs during rehash"] = ""; +$GLOBALS["i18n"]["A problem occurs during rehash"] = "Ein Problem ist beim Laden der Konfiguration aufgetreten"; // line 83 in chat.js.tpl.php -$GLOBALS["i18n"]["Choosen nickname is allready used"] = ""; +$GLOBALS["i18n"]["Choosen nickname is allready used"] = "Der gewählte Nickname ist schon vergeben"; // line 84 in chat.js.tpl.php -$GLOBALS["i18n"]["phpfreechat current version is %s"] = ""; +$GLOBALS["i18n"]["phpfreechat current version is %s"] = "Die installierte Version von phpfreechat ist %s"; // line 85 in chat.js.tpl.php -$GLOBALS["i18n"]["Maximum number of joined channels has been reached"] = ""; +$GLOBALS["i18n"]["Maximum number of joined channels has been reached"] = "Die maximale Anzahl der Channels ist erreicht"; // line 86 in chat.js.tpl.php -$GLOBALS["i18n"]["Maximum number of private chat has been reached"] = ""; +$GLOBALS["i18n"]["Maximum number of private chat has been reached"] = "Die maximale Anzahl der privaten Channels ist erreicht"; // line 88 in chat.js.tpl.php -$GLOBALS["i18n"]["Send"] = ""; - -?> \ No newline at end of file +$GLOBALS["i18n"]["Send"] = "Senden"; +?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-01 22:23:23
|
Revision: 885 http://svn.sourceforge.net/phpfreechat/?rev=885&view=rev Author: kerphi Date: 2006-12-01 14:23:19 -0800 (Fri, 01 Dec 2006) Log Message: ----------- [en] New esperanto translation ('eo' locale) (thanks to Andrey Yankovskiy) [15min] [fr] Nouvelle traduction en Esperanto (locale 'eo') (merci ?\195?\160 Andrey Yankovskiy) [15min] Modified Paths: -------------- trunk/demo/index.php Added Paths: ----------- trunk/demo/demo54_in_esperanto.php trunk/i18n/eo/ trunk/i18n/eo/main.php Added: trunk/demo/demo54_in_esperanto.php =================================================================== --- trunk/demo/demo54_in_esperanto.php (rev 0) +++ trunk/demo/demo54_in_esperanto.php 2006-12-01 22:23:19 UTC (rev 885) @@ -0,0 +1,36 @@ +<?php + +require_once dirname(__FILE__)."/../src/phpfreechat.class.php"; + +$params["serverid"] = md5(__FILE__); // calculate a unique id for this chat +$params["language"] = "eo"; +$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> + <meta http-equiv="content-type" content="text/html; charset=utf-8" /> + <title>phpFreeChat demo</title> + + <?php $chat->printJavascript(); ?> + <?php $chat->printStyle(); ?> + + </head> + + <body> + <?php $chat->printChat(); ?> + +<?php + // print the current file + echo "<h2>The source code</h2>"; + $filename = __FILE__; + echo "<p><code>".$filename."</code></p>"; + echo "<pre style=\"margin: 0 50px 0 50px; padding: 10px; background-color: #DDD;\">"; + $content = file_get_contents($filename); + echo htmlentities($content); + echo "</pre>"; +?> + + </body> +</html> Modified: trunk/demo/index.php =================================================================== --- trunk/demo/index.php 2006-12-01 09:05:32 UTC (rev 884) +++ trunk/demo/index.php 2006-12-01 22:23:19 UTC (rev 885) @@ -120,6 +120,7 @@ <li><a href="demo47_in_polish.php">demo47 - the Polish translation of the chat</a></li> <li><a href="demo52_in_bangla.php">demo52 - the Bangla translation of the chat</a></li> <li><a href="demo53_in_armenian.php">demo53 - the Armenian translation of the chat</a></li> + <li><a href="demo54_in_esperanto.php">demo54 - the Esperanto translation of the chat</a></li> </ul> </div> Added: trunk/i18n/eo/main.php =================================================================== --- trunk/i18n/eo/main.php (rev 0) +++ trunk/i18n/eo/main.php 2006-12-01 22:23:19 UTC (rev 885) @@ -0,0 +1,176 @@ +<?php +/** + * i18n/eo/main.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 + */ + +/** + * Esperanto translation of the messages (utf8 encoded!) + * + * @author Andrey Yankovskiy + */ + +// line 45 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["My Chat"] = "Nia babilejo"; + +// line 201 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s not found, %s library can't be found."] = "%s not found, %s library can't be found."; + +// line 355 in phpfreechat.class.php +$GLOBALS["i18n"]["Please enter your nickname"] = "Bonvolu enskribi vian voknomon"; + +// line 565 in phpfreechat.class.php +$GLOBALS["i18n"]["Text cannot be empty"] = "Hej! Vi forgesis skribi ion!!!"; + +// line 392 in phpfreechat.class.php +$GLOBALS["i18n"]["%s changes his nickname to %s"] = "%s changes his/her nickname to %s"; + +// line 398 in phpfreechat.class.php +$GLOBALS["i18n"]["%s is connected"] = "%s is connected"; + +// line 452 in phpfreechat.class.php +$GLOBALS["i18n"]["%s quit"] = "%s quit"; + +// line 468 in phpfreechat.class.php +$GLOBALS["i18n"]["%s disconnected (timeout)"] = "%s disconnected (timeout)"; + +// line 262 in phpfreechat.class.php +$GLOBALS["i18n"]["Unknown command [%s]"] = "Unknown command [%s]"; + +// line 149 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s doesn't exist: %s"] = "%s doesn't exist: %s"; + +// line 180 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["You need %s"] = "You need %s"; + +// line 241 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s doesn't exist, %s library can't be found"] = "%s doesn't exist, %s library can't be found"; + +// line 280 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s doesn't exist"] = "%s doesn't exist"; + +// line 433 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s directory must be specified"] = "%s directory must be specified"; + +// line 439 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s must be a directory"] = "%s must be a directory"; + +// line 446 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s can't be created"] = "%s can't be created"; + +// line 451 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s is not writeable"] = "%s is not writeable"; + +// line 496 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s is not readable"] = "%s is not readable"; + +// line 469 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s is not a file"] = "%s is not a file"; + +// line 491 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["%s is not a directory"] = "%s is not a directory"; + +// line 23 in chat.html.tpl.php +$GLOBALS["i18n"]["PHP FREE CHAT [powered by phpFreeChat-%s]"] = "PHP FREE CHAT [powered by phpFreeChat-%s]"; + +// line 296 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Hide nickname marker"] = "malkolorigi la nomon"; + +// line 304 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Show nickname marker"] = "kolorigi la nomon"; + +// line 389 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Disconnect"] = "Diskonekto"; + +// line 395 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Connect"] = "Konekto"; + +// line 427 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Magnify"] = "Malsxrumpi"; + +// line 434 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Cut down"] = "Sxrumpi"; + +// line 345 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Hide dates and hours"] = "Kasxi tempon"; + +// line 353 in javascript1.js.tpl.php +$GLOBALS["i18n"]["Show dates and hours"] = "Montri la tempon"; + +// line 21 in chat.html.tpl.php +$GLOBALS["i18n"]["Enter your message here"] = "Enskribu via mesagxo"; + +// line 24 in chat.html.tpl.php +$GLOBALS["i18n"]["Enter your nickname here"] = "Bonvolu enskribi vian nomon"; + +// line 93 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["Error: undefined or obsolete parameter '%s', please correct or remove this parameter"] = "Error: undefined or obsolete parameter '%s', please correct or remove this parameter"; + +// line 86 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Hide smiley box"] = "Kasxi la bildetaron"; + +// line 87 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Show smiley box"] = "Montri la bildetaron"; + +// line 88 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Hide online users box"] = "Kasxi la partoprenantojn"; + +// line 89 in pfcclient.js.tpl.php +$GLOBALS["i18n"]["Show online users box"] = "Montri la partoprenantojn"; + +// line 33 in chat.html.tpl.php +$GLOBALS["i18n"]["Bold"] = "Dike"; + +// line 34 in chat.html.tpl.php +$GLOBALS["i18n"]["Italics"] = "Kursive"; + +// line 35 in chat.html.tpl.php +$GLOBALS["i18n"]["Underline"] = "Substreke"; + +// line 36 in chat.html.tpl.php +$GLOBALS["i18n"]["Delete"] = "Forstreke"; + +// line 37 in chat.html.tpl.php +$GLOBALS["i18n"]["Pre"] = "Pre"; + +// line 38 in chat.html.tpl.php +$GLOBALS["i18n"]["Mail"] = "E-posxto"; + +// line 39 in chat.html.tpl.php +$GLOBALS["i18n"]["Color"] = "Koloro"; + +// line 48 in phpfreechattemplate.class.php +$GLOBALS["i18n"]["%s template could not be found"] = "%s template could not be found"; + +// line 512 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["Error: '%s' could not be found, please check your themepath '%s' and your theme '%s' are correct"] = "Error: '%s' could not be found, please check your themepath '%s' and your theme '%s' are correct"; + +// line 75 in pfccommand.class.php +$GLOBALS["i18n"]["%s must be implemented"] = "%s must be implemented"; + +// line 343 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["'%s' parameter is mandatory by default use '%s' value"] = "'%s' parameter is mandatory by default use '%s' value"; + +// line 378 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["'%s' parameter must be a positive number"] = "'%s' parameter must be a positive number"; + +// line 386 in phpfreechatconfig.class.php +$GLOBALS["i18n"]["'%s' parameter is not valid. Available values are : '%s'"] = "'%s' parameter is not valid. Available values are: '%s'"; + +?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-12-01 09:05:40
|
Revision: 884 http://svn.sourceforge.net/phpfreechat/?rev=884&view=rev Author: kerphi Date: 2006-12-01 01:05:32 -0800 (Fri, 01 Dec 2006) Log Message: ----------- http://www.phpfreechat.net/forum/viewtopic.php?id=895 Modified Paths: -------------- trunk/demo/demo27_dice.class.php Modified: trunk/demo/demo27_dice.class.php =================================================================== --- trunk/demo/demo27_dice.class.php 2006-11-29 17:26:09 UTC (rev 883) +++ trunk/demo/demo27_dice.class.php 2006-12-01 09:05:32 UTC (rev 884) @@ -22,7 +22,7 @@ function check($text){ $this->errors = array(); $this->command= ''; - if(preg_match('/^(\d)d(\d{1,3})([\+-]\d)?$/', $text, $matches)){ + if(preg_match('/^([0-9]+)d([0-9]{1,3})([\+-][0-9]+)?$/', $text, $matches)){ $this->command['launch'] = (int) $matches[1]; $this->command['faces'] = (int) $matches[2]; // Now go for corrections This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-11-29 17:26:18
|
Revision: 883 http://svn.sourceforge.net/phpfreechat/?rev=883&view=rev Author: kerphi Date: 2006-11-29 09:26:09 -0800 (Wed, 29 Nov 2006) Log Message: ----------- Bug fix: correct the sound button label order and refresh the button at startup Modified Paths: -------------- trunk/src/client/pfcclient.js Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-11-29 16:33:12 UTC (rev 882) +++ trunk/src/client/pfcclient.js 2006-11-29 17:26:09 UTC (rev 883) @@ -125,6 +125,7 @@ this.refresh_loginlogout(); this.refresh_minimize_maximize(); this.refresh_Smileys(); + this.refresh_sound(); this.refresh_nickmarker(); }, @@ -1412,13 +1413,13 @@ if (this.issoundenable) { snd_icon.src = this.res.getFileUrl('images/sound-on.gif'); - snd_icon.alt = this.res.getLabel('Play sound'); + snd_icon.alt = this.res.getLabel('Mute sound'); snd_icon.title = snd_icon.alt; } else { snd_icon.src = this.res.getFileUrl('images/sound-off.gif'); - snd_icon.alt = this.res.getLabel('Mute sound'); + snd_icon.alt = this.res.getLabel('Play sound'); snd_icon.title = snd_icon.alt; } }, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-11-29 16:33:16
|
Revision: 882 http://svn.sourceforge.net/phpfreechat/?rev=882&view=rev Author: kerphi Date: 2006-11-29 08:33:12 -0800 (Wed, 29 Nov 2006) Log Message: ----------- [en] Optimizations: when directories were open for listing, they were not closed using closedir() php function. [1h00] [fr] Optimisation : lorsque les repertoire ?\195?\169taient list?\195?\169s, ils n'?\195?\169tait jamais ferm?\195?\169s avec la fonction closedir() de php. [1h00] Modified Paths: -------------- trunk/src/commands/help.class.php trunk/src/containers/file.class.php trunk/src/pfci18n.class.php trunk/src/pfctools.php Modified: trunk/src/commands/help.class.php =================================================================== --- trunk/src/commands/help.class.php 2006-11-29 14:44:44 UTC (rev 881) +++ trunk/src/commands/help.class.php 2006-11-29 16:33:12 UTC (rev 882) @@ -26,6 +26,7 @@ if (!preg_match("/^([a-z]+).class.php$/i",$file,$res)) continue; if (!in_array($res[1],$ignore)) $cmdlist[] = $res[1]; } + closedir($dh); sort($cmdlist); $str = _pfc("Here is the command list:")."<br/>"; Modified: trunk/src/containers/file.class.php =================================================================== --- trunk/src/containers/file.class.php 2006-11-29 14:44:44 UTC (rev 881) +++ trunk/src/containers/file.class.php 2006-11-29 16:33:12 UTC (rev 882) @@ -134,6 +134,7 @@ $ret["timestamp"][] = filemtime($dir.'/'.$file); $ret["value"][] = $file; } + closedir($dh); } return $ret; } @@ -151,6 +152,7 @@ $ret["timestamp"][] = filemtime($dir.'/'.$file); $ret["value"][] = $file; } + closedir($dh); } return $ret; } @@ -197,10 +199,18 @@ return true; } - $leaffilename = $dir.'/'.$leaf; - + $leaffilename = $dir.'/'.$leaf; if (!file_exists($leaffilename)) return false; unlink($leaffilename); + + // check that the directory is empty or not + // remove it if it doesn't contains anything + $dh = opendir($dir); + readdir($dh); readdir($dh); // skip . and .. directories + $isnotempty = readdir($dh); + closedir($dh); + if ($isnotempty === false) rmdir($dir); + return true; } Modified: trunk/src/pfci18n.class.php =================================================================== --- trunk/src/pfci18n.class.php 2006-11-29 14:44:44 UTC (rev 881) +++ trunk/src/pfci18n.class.php 2006-11-29 16:33:12 UTC (rev 882) @@ -110,6 +110,7 @@ if (file_exists(dirname(__FILE__)."/../i18n/".$file."/admin.php")) $GLOBALS["accepted_admin_languages"][] = $file; } + closedir($dir_handle); return $GLOBALS["accepted_admin_languages"]; } else{ @@ -124,6 +125,7 @@ if ($file == "." || $file == ".." || strpos($file,".")===0) continue; $GLOBALS["accepted_languages"][] = $file; } + closedir($dir_handle); return $GLOBALS["accepted_languages"]; } } Modified: trunk/src/pfctools.php =================================================================== --- trunk/src/pfctools.php 2006-11-29 14:44:44 UTC (rev 881) +++ trunk/src/pfctools.php 2006-11-29 16:33:12 UTC (rev 882) @@ -135,6 +135,7 @@ if($obj=='.' || $obj=='..') continue; if (!@unlink($dir.'/'.$obj)) rm_r($dir.'/'.$obj); } + closedir($dh); @rmdir($dir); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-11-29 14:44:45
|
Revision: 881 http://svn.sourceforge.net/phpfreechat/?rev=881&view=rev Author: kerphi Date: 2006-11-29 06:44:44 -0800 (Wed, 29 Nov 2006) Log Message: ----------- [en] Bug fix: on windows server the public path was incorrectly computed [0h25] [fr] Bug fix : sur les serveurs windows le chemin public ?\195?\169tait mal calcul?\195?\169 [0h25] Modified Paths: -------------- trunk/src/pfcglobalconfig.class.php trunk/src/pfctools.php Modified: trunk/src/pfcglobalconfig.class.php =================================================================== --- trunk/src/pfcglobalconfig.class.php 2006-11-28 17:50:20 UTC (rev 880) +++ trunk/src/pfcglobalconfig.class.php 2006-11-29 14:44:44 UTC (rev 881) @@ -358,6 +358,7 @@ // calculate datapublic url if ($this->data_public_url == "") $this->data_public_url = relativePath($this->client_script_path, $this->data_public_path); + // --- // test server script if ($this->server_script_path == "") Modified: trunk/src/pfctools.php =================================================================== --- trunk/src/pfctools.php 2006-11-28 17:50:20 UTC (rev 880) +++ trunk/src/pfctools.php 2006-11-29 14:44:44 UTC (rev 881) @@ -62,11 +62,11 @@ $p1 = realpath(cleanPath($p1)); $p2 = realpath(cleanPath($p2)); $res = ""; - //echo $p1."<br>"; - //echo $p2."<br>"; + // echo $p1."<br>"; + // echo $p2."<br>"; while( $p1 != "" && $p1 != "/" && // for unix root dir - !preg_match("/[a-z]\:\\\/i",$p1) && // for windows rootdir + !preg_match("/^[a-z]\:\\\$/i",$p1) && // for windows rootdir strpos($p2, $p1) !== 0) { $res .= "../"; @@ -86,6 +86,7 @@ if (preg_match("/.*\/$/", $res)) $res = preg_replace("/(.*)\//","$1",$res); // if rootpath is empty replace it by "." to avoide url starting with "/" if ($res == "") $res = "."; + // echo $res."<br>"; return $res; } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-11-28 17:50:28
|
Revision: 880 http://svn.sourceforge.net/phpfreechat/?rev=880&view=rev Author: kerphi Date: 2006-11-28 09:50:20 -0800 (Tue, 28 Nov 2006) Log Message: ----------- [en] Add the sound notification using a small flash applet. It's possible to enable/disable the sound notification at startup with the 'startwithsound' parameter. (thanks to neohunter) [1h00] [fr] Ajoute la notification sonore par le biais d'une petite applet flash. Il est possible d'activer/d?\195?\169sactiver le son au d?\195?\169marrage grace au param?\195?\168tre 'startwithsound'. (merci ?\195?\160 neohunter) [1h00] Modified Paths: -------------- trunk/src/client/chat.js.tpl.php trunk/src/client/pfcclient.js trunk/src/client/pfcgui.js trunk/src/pfcglobalconfig.class.php trunk/themes/default/style.css Added Paths: ----------- trunk/themes/default/images/sound-off.gif trunk/themes/default/images/sound-on.gif trunk/themes/default/sound.swf Modified: trunk/src/client/chat.js.tpl.php =================================================================== --- trunk/src/client/chat.js.tpl.php 2006-11-28 16:52:37 UTC (rev 879) +++ trunk/src/client/chat.js.tpl.php 2006-11-28 17:50:20 UTC (rev 880) @@ -10,10 +10,11 @@ var pfc_clientid = <?php echo $json->encode(md5(uniqid(rand(), true))); ?>; var pfc_title = <?php echo $json->encode($title); ?>; var pfc_refresh_delay = <?php echo $json->encode($refresh_delay); ?>; -var pfc_max_refresh_delay = <?php echo $json->encode($max_refresh_delay); ?>; +var pfc_max_refresh_delay = <?php echo $json->encode($max_refresh_delay); ?>; var pfc_start_minimized = <?php echo $json->encode($start_minimized); ?>; var pfc_nickmarker = <?php echo $json->encode($nickmarker); ?>; var pfc_clock = <?php echo $json->encode($clock); ?>; +var pfc_startwithsound = <?php echo $json->encode($startwithsound); ?>; var pfc_showsmileys = <?php echo $json->encode($showsmileys); ?>; var pfc_showwhosonline = <?php echo $json->encode($showwhosonline); ?>; var pfc_focus_on_connect = <?php echo $json->encode($focus_on_connect); ?>; @@ -78,6 +79,8 @@ "You are not allowed to speak to yourself", // _pfc "Close", // _pfc "Choosen nickname is not allowed", // _pfc + "Play sound", // _pfc + "Mute sound", // _pfc ); foreach($labels_to_load as $l) { @@ -114,6 +117,9 @@ 'images/close-whoisbox.gif', 'images/openpv.gif', 'images/user-admin.gif', + 'images/sound-on.gif', + 'images/sound-off.gif', + 'sound.swf', ); foreach($fileurl_to_load as $f) Modified: trunk/src/client/pfcclient.js =================================================================== --- trunk/src/client/pfcclient.js 2006-11-28 16:52:37 UTC (rev 879) +++ trunk/src/client/pfcclient.js 2006-11-28 17:50:20 UTC (rev 880) @@ -117,6 +117,11 @@ if (cookie != null) this.switch_text_color(cookie); + cookie = getCookie('pfc_issoundenable'); + this.issoundenable = (cookie == 'true'); + if (cookie == '' || cookie == null) + this.issoundenable = pfc_startwithsound; + this.refresh_loginlogout(); this.refresh_minimize_maximize(); this.refresh_Smileys(); @@ -1389,6 +1394,36 @@ }, /** + * Sound button + */ + sound_swap: function() + { + if (this.issoundenable) { + this.issoundenable = false; + } else { + this.issoundenable = true; + } + this.refresh_sound(); + setCookie('pfc_issoundenable', this.issoundenable); + }, + refresh_sound: function( root ) + { + var snd_icon = $('pfc_sound'); + if (this.issoundenable) + { + snd_icon.src = this.res.getFileUrl('images/sound-on.gif'); + snd_icon.alt = this.res.getLabel('Play sound'); + snd_icon.title = snd_icon.alt; + } + else + { + snd_icon.src = this.res.getFileUrl('images/sound-off.gif'); + snd_icon.alt = this.res.getLabel('Mute sound'); + snd_icon.title = snd_icon.alt; + } + }, + + /** * Connect/disconnect button */ connect_disconnect: function() Modified: trunk/src/client/pfcgui.js =================================================================== --- trunk/src/client/pfcgui.js 2006-11-28 16:52:37 UTC (rev 879) +++ trunk/src/client/pfcgui.js 2006-11-28 17:50:20 UTC (rev 880) @@ -301,12 +301,29 @@ var rx = new RegExp('^\\[[0-9]+\\](.*)','ig'); document.title = document.title.replace(rx,'$1'); document.title = '['+this.windownotifynb+']'+document.title; + + // play the sound + var soundcontainer = document.getElementById('pfc_sound_container'); + if (pfc.issoundenable) + { + var flash = '<object style="visibility:hidden" classid="clsid:D27CDB6E-AE6D-11CF-96B8-444553540000" id="obj1" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,40,0" border="0">'; + flash += '<param name="movie" value="' + pfc.res.getFileUrl('sound.swf') + '">'; + flash += '<param name="quality" value="High">'; + flash += '<embed src="' + pfc.res.getFileUrl('sound.swf') + '" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" name="obj1">'; + flash += '</object>'; + soundcontainer.innerHTML = flash; + } }, unnotifyWindow: function() { this.windownotifynb = 0; var rx = new RegExp('^\\[[0-9]+\\](.*)','ig'); document.title = document.title.replace(rx,'$1'); + + // stop the sound + var soundcontainer = document.getElementById('pfc_sound_container'); + if (pfc.issoundenable) + soundcontainer.innerHTML = ''; }, /** @@ -537,6 +554,17 @@ btn.appendChild(img); cmdcontainer.appendChild(btn); + // button sound on/off + var btn = document.createElement('div'); + btn.setAttribute('class', 'pfc_btn'); + btn.setAttribute('className', 'pfc_btn'); // for IE6 + var img = document.createElement('img'); + img.setAttribute('id', 'pfc_sound'); + img.setAttribute('src', pfc.res.getFileUrl('images/sound-on.gif')); + img.onclick = function(){ pfc.sound_swap(); } + btn.appendChild(img); + cmdcontainer.appendChild(btn); + // button smileys on/off if (pfc_btn_sh_smileys) { @@ -677,6 +705,11 @@ smileybox.setAttribute('id', 'pfc_smileys'); inputcontainer.appendChild(smileybox); this.loadSmileyBox(); + + // sound container box : <div id="pfc_sound_container"> + var soundcontainerbox = document.createElement('div'); + soundcontainerbox.setAttribute('id', 'pfc_sound_container'); + inputcontainer.appendChild(soundcontainerbox); } }; Modified: trunk/src/pfcglobalconfig.class.php =================================================================== --- trunk/src/pfcglobalconfig.class.php 2006-11-28 16:52:37 UTC (rev 879) +++ trunk/src/pfcglobalconfig.class.php 2006-11-28 17:50:20 UTC (rev 880) @@ -82,6 +82,7 @@ var $shownotice = 3; // show: 0 = nothing, 1 = just nickname changes, 2 = join/quit, 3 = 1+2 var $nickmarker = true; // show/hide nicknames colors var $clock = true; // show/hide dates and hours + var $startwithsound = true; // start with sound enabled var $openlinknewwindow = true; // used to open the links in a new window var $notify_window = true; // true : appends a prefix to the window title with the number of new posted messages Added: trunk/themes/default/images/sound-off.gif =================================================================== (Binary files differ) Property changes on: trunk/themes/default/images/sound-off.gif ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/themes/default/images/sound-on.gif =================================================================== (Binary files differ) Property changes on: trunk/themes/default/images/sound-on.gif ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/themes/default/sound.swf =================================================================== (Binary files differ) Property changes on: trunk/themes/default/sound.swf ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Modified: trunk/themes/default/style.css =================================================================== --- trunk/themes/default/style.css 2006-11-28 16:52:37 UTC (rev 879) +++ trunk/themes/default/style.css 2006-11-28 17:50:20 UTC (rev 880) @@ -346,4 +346,9 @@ div#pfc_debug { font-size: 11px; +} +div#pfc_sound_container { + visibility:hidden; /* this box is hidden because it contains a flash sound media (sound.swf)*/ + width: 0; + height: 0; } \ No newline at end of file This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |