[Phpfreechat-svn] SF.net SVN: phpfreechat: [910] trunk
Status: Beta
Brought to you by:
kerphi
From: <ke...@us...> - 2006-12-29 11:57:58
|
Revision: 910 http://svn.sourceforge.net/phpfreechat/?rev=910&view=rev Author: kerphi Date: 2006-12-29 03:57:52 -0800 (Fri, 29 Dec 2006) Log Message: ----------- fix the loadBBCodeColorList function Modified Paths: -------------- trunk/data/public/js/pfcgui.js trunk/src/phpfreechat.class.php Modified: trunk/data/public/js/pfcgui.js =================================================================== --- trunk/data/public/js/pfcgui.js 2006-12-21 06:35:09 UTC (rev 909) +++ trunk/data/public/js/pfcgui.js 2006-12-29 11:57:52 UTC (rev 910) @@ -418,6 +418,27 @@ } }, + loadBBCodeColorList: function() + { + // color list + var clist = $('pfc_colorlist'); + var clist_v = pfc_bbcode_color_list; + for (var i=0 ; i<clist_v.length ; i++) + { + var bbc = clist_v[i]; + var elt = document.createElement('img'); + elt.bbc = bbc; + elt.setAttribute('class', 'pfc_color'); + elt.setAttribute('className', 'pfc_color'); // for IE6 + elt.setAttribute('id', 'pfc_color_'+bbc); + elt.style.backgroundColor = '#'+bbc; + elt.setAttribute('src', pfc.res.getFileUrl('images/color_transparent.gif')); + elt.setAttribute('alt', bbc); + elt.onclick = function(){ pfc.switch_text_color(this.bbc); } + clist.appendChild(elt); + } + }, + buildChat: function() { var container = $('pfc_container'); @@ -714,6 +735,5 @@ var soundcontainerbox = document.createElement('div'); soundcontainerbox.setAttribute('id', 'pfc_sound_container'); container.appendChild(soundcontainerbox); - } - + } }; Modified: trunk/src/phpfreechat.class.php =================================================================== --- trunk/src/phpfreechat.class.php 2006-12-21 06:35:09 UTC (rev 909) +++ trunk/src/phpfreechat.class.php 2006-12-29 11:57:52 UTC (rev 910) @@ -393,7 +393,7 @@ } - function loadStyles($theme = 'default', &$xml_reponse = null) + function loadStyles($theme = 'default', &$xml_reponse) { if ($xml_reponse == null) $xml_reponse = new xajaxResponse(); @@ -440,7 +440,7 @@ return $xml_reponse; } - function loadScripts($theme = 'default', &$xml_reponse = null) + function loadScripts($theme, &$xml_reponse) { if ($xml_reponse == null) $xml_reponse = new xajaxResponse(); @@ -556,7 +556,7 @@ } - function loadInterface($theme = 'default', &$xml_reponse = null) + function loadInterface($theme = 'default', &$xml_reponse) { if ($xml_reponse == null) $xml_reponse = new xajaxResponse(); @@ -581,9 +581,9 @@ return $xml_reponse; } - function loadChat($theme = 'default', &$xml_reponse = null) + function loadChat($theme = 'default') { - if ($xml_reponse == null) $xml_reponse = new xajaxResponse(); + $xml_reponse = new xajaxResponse(); $this->loadInterface($theme,$xml_reponse); $this->loadStyles($theme,$xml_reponse); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |