Thread: [Phpfreechat-svn] SF.net SVN: phpfreechat: [497] trunk/demo
Status: Beta
Brought to you by:
kerphi
From: <ke...@us...> - 2006-05-18 08:16:16
|
Revision: 497 Author: kerphi Date: 2006-05-18 01:15:57 -0700 (Thu, 18 May 2006) ViewCVS: http://svn.sourceforge.net/phpfreechat/?rev=497&view=rev Log Message: ----------- Add a demo which shows how to customize the nicknames automatic colors. Modified Paths: -------------- branches/0.x/demo/index.php trunk/demo/index.php Added Paths: ----------- branches/0.x/demo/demo43_change_the_nicknames_colors/ branches/0.x/demo/demo43_change_the_nicknames_colors/mytheme/ branches/0.x/demo/demo43_change_the_nicknames_colors/mytheme/templates/ branches/0.x/demo/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php branches/0.x/demo/demo43_change_the_nicknames_colors.php trunk/demo/demo43_change_the_nicknames_colors/ trunk/demo/demo43_change_the_nicknames_colors/mytheme/ trunk/demo/demo43_change_the_nicknames_colors/mytheme/templates/ trunk/demo/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php trunk/demo/demo43_change_the_nicknames_colors.php Added: branches/0.x/demo/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php =================================================================== --- branches/0.x/demo/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php (rev 0) +++ branches/0.x/demo/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php 2006-05-18 08:15:57 UTC (rev 497) @@ -0,0 +1,9 @@ +pfcClient.prototype.reloadColorList = function() +{ + this.colorlist = Array( 'green', + 'blue', + 'red', + '#567', + '#C33B3B' + ); +} \ No newline at end of file Added: branches/0.x/demo/demo43_change_the_nicknames_colors.php =================================================================== --- branches/0.x/demo/demo43_change_the_nicknames_colors.php (rev 0) +++ branches/0.x/demo/demo43_change_the_nicknames_colors.php 2006-05-18 08:15:57 UTC (rev 497) @@ -0,0 +1,46 @@ +<?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,10); // setup the intitial nickname +$params["title"] = "A chat with a customized nickname color list"; +$params["themepath"] = dirname(__FILE__)."/demo43_change_the_nicknames_colors"; +$params["theme"] = "mytheme"; +$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>"; +?> + +<?php + $filename = dirname(__FILE__)."/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php"; + 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: branches/0.x/demo/index.php =================================================================== --- branches/0.x/demo/index.php 2006-05-18 08:11:11 UTC (rev 496) +++ branches/0.x/demo/index.php 2006-05-18 08:15:57 UTC (rev 497) @@ -28,7 +28,7 @@ <li><a href="demo32_show_last_messages-showlastmsg.php">demo32 - demo which show how to get the last posted messages (showlastmsg script)</a></li> --> <li><a href="demo35_shared_memory.php">demo35 - demo which show how to use the shared memory container</a></li> - + <li><a href="demo43_change_the_nicknames_colors.php">demo43 - demo which show how to change the nicknames automatic colors</a></li> </ul> Added: trunk/demo/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php =================================================================== --- trunk/demo/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php (rev 0) +++ trunk/demo/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php 2006-05-18 08:15:57 UTC (rev 497) @@ -0,0 +1,9 @@ +pfcClient.prototype.reloadColorList = function() +{ + this.colorlist = Array( 'green', + 'blue', + 'red', + '#567', + '#C33B3B' + ); +} \ No newline at end of file Added: trunk/demo/demo43_change_the_nicknames_colors.php =================================================================== --- trunk/demo/demo43_change_the_nicknames_colors.php (rev 0) +++ trunk/demo/demo43_change_the_nicknames_colors.php 2006-05-18 08:15:57 UTC (rev 497) @@ -0,0 +1,46 @@ +<?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,10); // setup the intitial nickname +$params["title"] = "A chat with a customized nickname color list"; +$params["themepath"] = dirname(__FILE__)."/demo43_change_the_nicknames_colors"; +$params["theme"] = "mytheme"; +$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>"; +?> + +<?php + $filename = dirname(__FILE__)."/demo43_change_the_nicknames_colors/mytheme/templates/pfcclient-custo.js.tpl.php"; + 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-05-18 08:11:11 UTC (rev 496) +++ trunk/demo/index.php 2006-05-18 08:15:57 UTC (rev 497) @@ -1,51 +1,51 @@ <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html> - <head> - <meta http-equiv="content-type" content="text/html; charset=utf-8"> - <title>phpFreeChat Demos</title> - <link rel="stylesheet" title="classic" type="text/css" href="../style/generic.css"> - <link rel="stylesheet" title="classic" type="text/css" href="../style/header.css"> - <link rel="stylesheet" title="classic" type="text/css" href="../style/footer.css"> - <link rel="stylesheet" title="classic" type="text/css" href="../style/menu.css"> + <head> + <meta http-equiv="content-type" content="text/html; charset=utf-8"> + <title>phpFreeChat Demos</title> + <link rel="stylesheet" title="classic" type="text/css" href="../style/generic.css"> + <link rel="stylesheet" title="classic" type="text/css" href="../style/header.css"> + <link rel="stylesheet" title="classic" type="text/css" href="../style/footer.css"> + <link rel="stylesheet" title="classic" type="text/css" href="../style/menu.css"> <link rel="stylesheet" title="classic" type="text/css" href="../style/content.css"> </head> - <body> - -<div class="header"> - <h1>phpFreeChat - Demos</h1> - <img alt="logo bulle" src="../style/bulle.png" class="logo2"> -</div> - -<div class="menu"> + <body> + +<div class="header"> + <h1>phpFreeChat - Demos</h1> + <img alt="logo bulle" src="../style/bulle.png" class="logo2"> +</div> + +<div class="menu"> <ul> - <li class="sub title">General</li> - <li> - <ul class="sub"> - <li class="item"> - <a href="../index.php">PFC Index</a> - </li> - </ul> - </li> - <li class="sub title">Demos</li> - <li> - <ul class="sub"> - <li class="item"> - <a href="#Miscellaneous">Miscellaneous</a> - </li> - <li class="item"> - <a href="#Themes">Themes</a> - </li> - <li class="item"> - <a href="#Translations">Translations</a> - </li> - </ul> - </li> - </ul> - <p class="partner"> - <a href="http://www.phpfreechat.net"><img alt="logo big" src="../style/logo_88x31.gif"></a> - </p> -</div> - + <li class="sub title">General</li> + <li> + <ul class="sub"> + <li class="item"> + <a href="../index.php">PFC Index</a> + </li> + </ul> + </li> + <li class="sub title">Demos</li> + <li> + <ul class="sub"> + <li class="item"> + <a href="#Miscellaneous">Miscellaneous</a> + </li> + <li class="item"> + <a href="#Themes">Themes</a> + </li> + <li class="item"> + <a href="#Translations">Translations</a> + </li> + </ul> + </li> + </ul> + <p class="partner"> + <a href="http://www.phpfreechat.net"><img alt="logo big" src="../style/logo_88x31.gif"></a> + </p> +</div> + <div class="content"> <h2>Miscellaneous</h2> @@ -69,7 +69,7 @@ <li><a href="demo32_show_last_messages-showlastmsg.php">demo32 - demo which show how to get the last posted messages (showlastmsg script)</a></li> --> <li><a href="demo35_shared_memory.php">demo35 - demo which show how to use the shared memory container</a></li> - + <li><a href="demo43_change_the_nicknames_colors.php">demo43 - demo which show how to change the nicknames automatic colors</a></li> </ul> @@ -109,18 +109,18 @@ <li><a href="demo41_in_greek.php">demo41 - the greek translation of the chat</a></li> <li><a href="demo42_in_chinese_from_taiwan.php">demo42 - the Chinese from taiwan (traditional Chinese) translation of the chat</a></li> </ul> - -</div> - -<div class="footer"> - <div class="valid"> - <a href="http://validator.w3.org/check?uri=referer"> - <img alt="Valid XHTML 1.0!" src="../style/valid-xhtml.png"> - </a> - <a href="http://jigsaw.w3.org/css-validator/check/referer"> - <img alt="Valid CSS!" src="../style/valid-css.png"> - </a> - </div> - <p>\xA92006 phpFreeChat</p> - </div> + +</div> + +<div class="footer"> + <div class="valid"> + <a href="http://validator.w3.org/check?uri=referer"> + <img alt="Valid XHTML 1.0!" src="../style/valid-xhtml.png"> + </a> + <a href="http://jigsaw.w3.org/css-validator/check/referer"> + <img alt="Valid CSS!" src="../style/valid-css.png"> + </a> + </div> + <p>\xA92006 phpFreeChat</p> + </div> </body></html> \ 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-08-18 22:09:59
|
Revision: 682 Author: kerphi Date: 2006-08-18 15:09:53 -0700 (Fri, 18 Aug 2006) ViewCVS: http://svn.sourceforge.net/phpfreechat/?rev=682&view=rev Log Message: ----------- Bug fix: the nickname encoding was not correctly converted according to the output_encoding parameter (cf demo8). Modified Paths: -------------- trunk/demo/demo8_with_a_iso-8859-1_encoded_page.php trunk/src/client/chat.js.tpl.php Modified: trunk/demo/demo8_with_a_iso-8859-1_encoded_page.php =================================================================== --- trunk/demo/demo8_with_a_iso-8859-1_encoded_page.php 2006-08-18 21:58:42 UTC (rev 681) +++ trunk/demo/demo8_with_a_iso-8859-1_encoded_page.php 2006-08-18 22:09:53 UTC (rev 682) @@ -1,5 +1,8 @@ <?php +// force the encoding because off some strange configured server +header("Content-Type: text/html; charset=ISO-8859-1"); + require_once dirname(__FILE__)."/../src/phpfreechat.class.php"; $params["serverid"] = md5(__FILE__); // calculate a unique id for this chat Modified: trunk/src/client/chat.js.tpl.php =================================================================== --- trunk/src/client/chat.js.tpl.php 2006-08-18 21:58:42 UTC (rev 681) +++ trunk/src/client/chat.js.tpl.php 2006-08-18 22:09:53 UTC (rev 682) @@ -1,5 +1,5 @@ var pfc_version = '<?php echo $version; ?>'; -var pfc_nickname = '<?php echo addslashes($u->nick); ?>'; +var pfc_nickname = '<?php echo ($GLOBALS["output_encoding"]=="UTF-8" ? addslashes($u->nick) : iconv("UTF-8", $GLOBALS["output_encoding"],addslashes($u->nick))); ?>'; var pfc_clientid = '<?php echo md5(uniqid(rand(), true)); ?>'; var pfc_title = '<?php echo addslashes($title); ?>'; var pfc_refresh_delay = <?php echo $refresh_delay; ?>; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2007-11-03 16:09:18
|
Revision: 1205 http://phpfreechat.svn.sourceforge.net/phpfreechat/?rev=1205&view=rev Author: kerphi Date: 2007-11-03 09:09:23 -0700 (Sat, 03 Nov 2007) Log Message: ----------- Correct some depreciated code Modified Paths: -------------- trunk/demo/demo1_simple.php trunk/demo/demo50_customized_usermetadata.php Modified: trunk/demo/demo1_simple.php =================================================================== --- trunk/demo/demo1_simple.php 2007-11-03 16:04:33 UTC (rev 1204) +++ trunk/demo/demo1_simple.php 2007-11-03 16:09:23 UTC (rev 1205) @@ -12,9 +12,6 @@ <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <title>phpFreeChat demo</title> - - <?php $chat->printJavascript(); ?> - <?php $chat->printStyle(); ?> </head> <body> Modified: trunk/demo/demo50_customized_usermetadata.php =================================================================== --- trunk/demo/demo50_customized_usermetadata.php 2007-11-03 16:04:33 UTC (rev 1204) +++ trunk/demo/demo50_customized_usermetadata.php 2007-11-03 16:09:23 UTC (rev 1205) @@ -16,10 +16,6 @@ <head> <meta http-equiv="content-type" content="text/html; charset=utf-8" /> <title>phpFreeChat demo</title> - - <?php $chat->printJavascript(); ?> - <?php $chat->printStyle(); ?> - </head> <body> @@ -39,7 +35,7 @@ <?php // print the current file echo "<h2>The customized javascript</h2>"; - $filename = dirname(__FILE__).'/demo50_data/mytheme/customize.js'; + $filename = dirname(__FILE__).'/demo50_data/mytheme/customize.js.php'; echo "<p><code>".$filename."</code></p>"; echo "<pre style=\"margin: 0 50px 0 50px; padding: 10px; background-color: #DDD;\">"; $content = file_get_contents($filename); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-08-29 21:04:43
|
Revision: 718 Author: kerphi Date: 2006-08-29 14:04:36 -0700 (Tue, 29 Aug 2006) ViewCVS: http://svn.sourceforge.net/phpfreechat/?rev=718&view=rev Log Message: ----------- fix demo43 Modified Paths: -------------- trunk/demo/demo43_change_the_nicknames_colors.php trunk/demo/index.php Removed Paths: ------------- trunk/demo/demo43_change_the_nicknames_colors/ Modified: trunk/demo/demo43_change_the_nicknames_colors.php =================================================================== --- trunk/demo/demo43_change_the_nicknames_colors.php 2006-08-29 21:01:10 UTC (rev 717) +++ trunk/demo/demo43_change_the_nicknames_colors.php 2006-08-29 21:04:36 UTC (rev 718) @@ -5,8 +5,7 @@ $params["serverid"] = md5(__FILE__); // calculate a unique id for this chat $params["nick"] = "guest".rand(1,10); // setup the intitial nickname $params["title"] = "A chat with a customized nickname color list"; -$params["themepath"] = dirname(__FILE__)."/demo43_change_the_nicknames_colors"; -$params["theme"] = "mytheme"; +$params["nickname_colorlist"] = array('#FF0000','#00FF00','#0000FF'); $chat = new phpFreeChat( $params ); ?> Modified: trunk/demo/index.php =================================================================== --- trunk/demo/index.php 2006-08-29 21:01:10 UTC (rev 717) +++ trunk/demo/index.php 2006-08-29 21:04:36 UTC (rev 718) @@ -73,7 +73,7 @@ <li><a href="demo32_show_last_messages-showlastmsg.php">demo32 - demo which show how to get the last posted messages (showlastmsg script)</a></li> <li><a href="demo35_shared_memory.php">demo35 - demo which show how to use the shared memory container</a> (not yet working)</li> - <li><a href="demo43_change_the_nicknames_colors.php">demo43 - demo which show how to change the nicknames automatic colors</a> (not yet working)</li> + <li><a href="demo43_change_the_nicknames_colors.php">demo43 - demo which show how to change the nicknames automatic colors</a></li> </ul> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2006-10-04 01:48:42
|
Revision: 806 http://svn.sourceforge.net/phpfreechat/?rev=806&view=rev Author: kerphi Date: 2006-09-30 15:47:11 -0700 (Sat, 30 Sep 2006) Log Message: ----------- [en] Add demo50 which shows how to use user metadata : add avatar (images) to each connected users. [40min] [fr] Ajout de la demo50 qui montre comment utiliser les m?\195?\169tadonn?\195?\169es utilisateurs : ajout d'un avatar (image) dans la boite whois de chaque utilisateur connect?\195?\169. [40min] Modified Paths: -------------- trunk/demo/index.php Added Paths: ----------- trunk/demo/demo50_customized_usermetadata.php trunk/demo/demo50_data/ trunk/demo/demo50_data/avatar1.jpg trunk/demo/demo50_data/avatar2.jpg trunk/demo/demo50_data/avatar3.jpg trunk/demo/demo50_data/avatar4.jpg trunk/demo/demo50_data/avatar5.jpg trunk/demo/demo50_data/avatar6.jpg trunk/demo/demo50_data/avatar7.jpg trunk/demo/demo50_data/avatar8.jpg trunk/demo/demo50_data/avatar9.jpg trunk/demo/demo50_data/mytheme/ trunk/demo/demo50_data/mytheme/customize.js trunk/demo/demo50_data/mytheme/style.css Added: trunk/demo/demo50_customized_usermetadata.php =================================================================== --- trunk/demo/demo50_customized_usermetadata.php (rev 0) +++ trunk/demo/demo50_customized_usermetadata.php 2006-09-30 22:47:11 UTC (rev 806) @@ -0,0 +1,40 @@ +<?php + +require_once dirname(__FILE__)."/../src/phpfreechat.class.php"; + +$params["serverid"] = md5(__FILE__); // calculate a unique id for this chat +$params["title"] = "A chat which shows how to use user metadata : add avatar (images) to each connected users"; +$params["nick"] = "guest".rand(1,1000); +$params["nickmeta"] = array("avatar" => "demo50_data/avatar".rand(1,10).".jpg"); +$params["themepath"] = dirname(__FILE__)."/demo50_data"; +$params["theme"] = "mytheme"; +$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 Added: trunk/demo/demo50_data/avatar1.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar1.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/avatar2.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar2.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/avatar3.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar3.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/avatar4.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar4.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/avatar5.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar5.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/avatar6.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar6.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/avatar7.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar7.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/avatar8.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar8.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/avatar9.jpg =================================================================== (Binary files differ) Property changes on: trunk/demo/demo50_data/avatar9.jpg ___________________________________________________________________ Name: svn:mime-type + application/octet-stream Added: trunk/demo/demo50_data/mytheme/customize.js =================================================================== --- trunk/demo/demo50_data/mytheme/customize.js (rev 0) +++ trunk/demo/demo50_data/mytheme/customize.js 2006-09-30 22:47:11 UTC (rev 806) @@ -0,0 +1,99 @@ +pfcClient.prototype.updateNickWhoisBox = function(nickid) + { + var div = document.createElement('div'); + div.setAttribute('class', 'pfc_nickwhois'); + div.setAttribute('className', 'pfc_nickwhois'); // for IE6 + + var ul = document.createElement('ul'); + div.appendChild(ul); + + // add the close button + var li = document.createElement('li'); + li.setAttribute('class', 'pfc_nickwhois_close'); + li.setAttribute('className', 'pfc_nickwhois_close'); // for IE6 + ul.appendChild(li); + var a = document.createElement('a'); + a.setAttribute('href', ''); + a.pfc_parent = div; + a.onclick = function(evt){ + this.pfc_parent.style.display = 'none'; + return false; + } + var img = document.createElement('img'); + img.setAttribute('src', this.res.getFileUrl('images/close-whoisbox.gif')); + img.alt = document.createTextNode(this.res.getLabel('Close')); + a.appendChild(img); + li.appendChild(a); + + // add the privmsg link (do not add it if this button is yourself) + if (pfc.getUserMeta(nickid,'nick') != this.nickname) + { + var li = document.createElement('li'); + li.setAttribute('class', 'pfc_nickwhois_pv'); + li.setAttribute('className', 'pfc_nickwhois_pv'); // for IE6 + ul.appendChild(li); + var a = document.createElement('a'); + a.setAttribute('href', ''); + a.pfc_nickid = nickid; + a.pfc_parent = div; + a.onclick = function(evt){ + var nick = pfc.getUserMeta(this.pfc_nickid,'nick'); + pfc.sendRequest('/privmsg', nick); + this.pfc_parent.style.display = 'none'; + return false; + } + var img = document.createElement('img'); + img.setAttribute('src', this.res.getFileUrl('images/openpv.gif')); + img.alt = document.createTextNode(this.res.getLabel('Private message')); + a.appendChild(img); + a.appendChild(document.createTextNode(this.res.getLabel('Private message'))); + li.appendChild(a); + } + + + // add the whois information table + var table = document.createElement('table'); +// table.setAttribute('cellspacing',0); +// table.setAttribute('cellpadding',0); +// table.setAttribute('border',0); + var tbody = document.createElement('tbody'); + table.appendChild(tbody); + var um = this.getAllUserMeta(nickid); + var um_keys = um.keys(); + var msg = ''; + for (var i=0; i<um_keys.length; i++) + { + var k = um_keys[i]; + var v = um[k]; + if (v && k != 'nickid' + && k != 'floodtime' + && k != 'flood_nbmsg' + && k != 'flood_nbchar' + && k != 'avatar' + ) + { + var tr = document.createElement('tr'); + var td1 = document.createElement('td'); + td1.setAttribute('class', 'pfc_nickwhois_c1'); + td1.setAttribute('className', 'pfc_nickwhois_c1'); // for IE6 + var td2 = document.createElement('td'); + td2.setAttribute('class', 'pfc_nickwhois_c2'); + td2.setAttribute('className', 'pfc_nickwhois_c2'); // for IE6 + td1.appendChild(document.createTextNode(k)); + td2.appendChild(document.createTextNode(v)); + tr.appendChild(td1); + tr.appendChild(td2); + tbody.appendChild(tr); + } + } + div.appendChild(table); + + // append the avatar image + var img = document.createElement('img'); + img.setAttribute('src',this.getUserMeta(nickid,'avatar')); + img.setAttribute('class', 'pfc_nickwhois_avatar'); + img.setAttribute('className', 'pfc_nickwhois_avatar'); // for IE6 + div.appendChild(img); + + this.nickwhoisbox[nickid] = div; + } \ No newline at end of file Added: trunk/demo/demo50_data/mytheme/style.css =================================================================== --- trunk/demo/demo50_data/mytheme/style.css (rev 0) +++ trunk/demo/demo50_data/mytheme/style.css 2006-09-30 22:47:11 UTC (rev 806) @@ -0,0 +1,3 @@ +img.pfc_nickwhois_avatar { + margin: 10px; +} \ No newline at end of file Modified: trunk/demo/index.php =================================================================== --- trunk/demo/index.php 2006-09-30 22:44:49 UTC (rev 805) +++ trunk/demo/index.php 2006-09-30 22:47:11 UTC (rev 806) @@ -74,6 +74,7 @@ <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> </ul> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2007-03-04 13:37:48
|
Revision: 983 http://svn.sourceforge.net/phpfreechat/?rev=983&view=rev Author: kerphi Date: 2007-03-04 05:37:46 -0800 (Sun, 04 Mar 2007) Log Message: ----------- add comments Modified Paths: -------------- trunk/demo/demo31_show_who_is_online-chat.php trunk/demo/demo31_show_who_is_online-whoisonline.php Modified: trunk/demo/demo31_show_who_is_online-chat.php =================================================================== --- trunk/demo/demo31_show_who_is_online-chat.php 2007-02-28 17:58:04 UTC (rev 982) +++ trunk/demo/demo31_show_who_is_online-chat.php 2007-03-04 13:37:46 UTC (rev 983) @@ -22,7 +22,8 @@ <body> <?php $chat->printChat(); ?> - + <p>Then have a look to the <a href="./demo31_show_who_is_online-whoisonline.php">whoisonline script</a></p> + <?php // print the current file echo "<h2>The source code</h2>"; Modified: trunk/demo/demo31_show_who_is_online-whoisonline.php =================================================================== --- trunk/demo/demo31_show_who_is_online-whoisonline.php 2007-02-28 17:58:04 UTC (rev 982) +++ trunk/demo/demo31_show_who_is_online-whoisonline.php 2007-03-04 13:37:46 UTC (rev 983) @@ -17,7 +17,7 @@ $info = "<strong>%d</strong> users are connected to the server !"; echo "<p>".sprintf($info, $nb_users)."</p>"; -echo "<p>Here is the nicknames' list:</p>"; +echo "<p>Here is the online nicknames list of <a href='./demo31_show_who_is_online-chat.php'>this chat</a>:</p>"; echo "<ul>"; foreach($users as $u) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <ke...@us...> - 2008-03-23 20:07:07
|
Revision: 1227 http://phpfreechat.svn.sourceforge.net/phpfreechat/?rev=1227&view=rev Author: kerphi Date: 2008-03-23 13:07:12 -0700 (Sun, 23 Mar 2008) Log Message: ----------- improve the demo source code readability Modified Paths: -------------- trunk/demo/demo10_in_chinese.php trunk/demo/demo12_phoenity_smiley_theme.php trunk/demo/demo13_in_german_informal_language.php trunk/demo/demo14_in_german_formal_language.php trunk/demo/demo15_multiple_channel.php trunk/demo/demo16_in_arabic.php trunk/demo/demo17_cerutti_smiley_theme.php trunk/demo/demo18_phpbb2_smiley_theme.php trunk/demo/demo19_in_japanese.php trunk/demo/demo1_simple.php trunk/demo/demo20_in_brazilian_portuguese.php trunk/demo/demo21_with_hardcoded_urls.php trunk/demo/demo22_in_serbian_croatian.php trunk/demo/demo23_in_italian.php trunk/demo/demo24_in_spanish.php trunk/demo/demo25_in_indonesian.php trunk/demo/demo26_in_swedish.php trunk/demo/demo27_customized_command.php trunk/demo/demo28_blune_theme.php trunk/demo/demo28_mini_blune_theme.php trunk/demo/demo29_in_russian.php trunk/demo/demo2_simple_with_params.php trunk/demo/demo31_show_who_is_online-chat.php trunk/demo/demo31_show_who_is_online-whoisonline.php trunk/demo/demo32_show_last_messages-chat.php trunk/demo/demo32_show_last_messages-showlastmsg.php trunk/demo/demo33_in_portuguese_from_portugal.php trunk/demo/demo34_add_a_link_on_nicknames.php trunk/demo/demo35_shared_memory.php trunk/demo/demo36_in_ukrainian.php trunk/demo/demo37_in_dutch_from_netherlands.php trunk/demo/demo38_in_norwegian_bokmal.php trunk/demo/demo39_in_bosnian.php trunk/demo/demo3_client.php trunk/demo/demo40_in_turkish.php trunk/demo/demo41_in_greek.php trunk/demo/demo42_in_chinese_from_taiwan.php trunk/demo/demo43_change_the_nicknames_colors.php trunk/demo/demo44_green_theme.php trunk/demo/demo45_in_bulgarian.php trunk/demo/demo46_in_hungarian.php trunk/demo/demo47_in_polish.php trunk/demo/demo48_custom_proxy.php trunk/demo/demo49_msn_smiley_theme.php trunk/demo/demo4_simulate_slow_server.php trunk/demo/demo50_customized_usermetadata.php trunk/demo/demo51_zilveer_theme.php trunk/demo/demo52_in_bangla.php trunk/demo/demo53_in_armenian.php trunk/demo/demo54_in_esperanto.php trunk/demo/demo55_mysql_container.php trunk/demo/demo56_in_romanian.php trunk/demo/demo57_in_korean.php trunk/demo/demo58_in_danish.php trunk/demo/demo59_in_norwegian_nynorsk.php trunk/demo/demo5_customized_style.php trunk/demo/demo60_in_vietnamese.php trunk/demo/demo61_in_croatian.php trunk/demo/demo62_in_belgian_dutch.php trunk/demo/demo63_in_thai.php trunk/demo/demo64_in_galician.php trunk/demo/demo65_metadata_and_html.php trunk/demo/demo6_in_french.php trunk/demo/demo7_in_english.php trunk/demo/demo8_with_a_iso-8859-1_encoded_page.php trunk/demo/demo9_with_a_utf8_encoded_nickname.php Modified: trunk/demo/demo10_in_chinese.php =================================================================== --- trunk/demo/demo10_in_chinese.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo10_in_chinese.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo12_phoenity_smiley_theme.php =================================================================== --- trunk/demo/demo12_phoenity_smiley_theme.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo12_phoenity_smiley_theme.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -30,7 +30,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo13_in_german_informal_language.php =================================================================== --- trunk/demo/demo13_in_german_informal_language.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo13_in_german_informal_language.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo14_in_german_formal_language.php =================================================================== --- trunk/demo/demo14_in_german_formal_language.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo14_in_german_formal_language.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo15_multiple_channel.php =================================================================== --- trunk/demo/demo15_multiple_channel.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo15_multiple_channel.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -37,7 +37,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo16_in_arabic.php =================================================================== --- trunk/demo/demo16_in_arabic.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo16_in_arabic.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo17_cerutti_smiley_theme.php =================================================================== --- trunk/demo/demo17_cerutti_smiley_theme.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo17_cerutti_smiley_theme.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -30,7 +30,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo18_phpbb2_smiley_theme.php =================================================================== --- trunk/demo/demo18_phpbb2_smiley_theme.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo18_phpbb2_smiley_theme.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -30,7 +30,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo19_in_japanese.php =================================================================== --- trunk/demo/demo19_in_japanese.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo19_in_japanese.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo1_simple.php =================================================================== --- trunk/demo/demo1_simple.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo1_simple.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -24,7 +24,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> </body> Modified: trunk/demo/demo20_in_brazilian_portuguese.php =================================================================== --- trunk/demo/demo20_in_brazilian_portuguese.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo20_in_brazilian_portuguese.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo21_with_hardcoded_urls.php =================================================================== --- trunk/demo/demo21_with_hardcoded_urls.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo21_with_hardcoded_urls.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -39,7 +39,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo22_in_serbian_croatian.php =================================================================== --- trunk/demo/demo22_in_serbian_croatian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo22_in_serbian_croatian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo23_in_italian.php =================================================================== --- trunk/demo/demo23_in_italian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo23_in_italian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo24_in_spanish.php =================================================================== --- trunk/demo/demo24_in_spanish.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo24_in_spanish.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo25_in_indonesian.php =================================================================== --- trunk/demo/demo25_in_indonesian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo25_in_indonesian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo26_in_swedish.php =================================================================== --- trunk/demo/demo26_in_swedish.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo26_in_swedish.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo27_customized_command.php =================================================================== --- trunk/demo/demo27_customized_command.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo27_customized_command.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -70,7 +70,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo28_blune_theme.php =================================================================== --- trunk/demo/demo28_blune_theme.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo28_blune_theme.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -29,7 +29,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo28_mini_blune_theme.php =================================================================== --- trunk/demo/demo28_mini_blune_theme.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo28_mini_blune_theme.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -31,7 +31,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo29_in_russian.php =================================================================== --- trunk/demo/demo29_in_russian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo29_in_russian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo2_simple_with_params.php =================================================================== --- trunk/demo/demo2_simple_with_params.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo2_simple_with_params.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -46,7 +46,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo31_show_who_is_online-chat.php =================================================================== --- trunk/demo/demo31_show_who_is_online-chat.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo31_show_who_is_online-chat.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -32,14 +32,14 @@ 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); + highlight_string($content); echo "</pre>"; $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); + highlight_string($content); echo "</pre>"; ?> </body> Modified: trunk/demo/demo31_show_who_is_online-whoisonline.php =================================================================== --- trunk/demo/demo31_show_who_is_online-whoisonline.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo31_show_who_is_online-whoisonline.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -36,13 +36,13 @@ 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); + highlight_string($content); echo "</pre>"; $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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo32_show_last_messages-chat.php =================================================================== --- trunk/demo/demo32_show_last_messages-chat.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo32_show_last_messages-chat.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -26,14 +26,14 @@ 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); + highlight_string($content); echo "</pre>"; $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); + highlight_string($content); echo "</pre>"; ?> </body> Modified: trunk/demo/demo32_show_last_messages-showlastmsg.php =================================================================== --- trunk/demo/demo32_show_last_messages-showlastmsg.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo32_show_last_messages-showlastmsg.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -46,13 +46,13 @@ 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); + highlight_string($content); echo "</pre>"; $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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo33_in_portuguese_from_portugal.php =================================================================== --- trunk/demo/demo33_in_portuguese_from_portugal.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo33_in_portuguese_from_portugal.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo34_add_a_link_on_nicknames.php =================================================================== --- trunk/demo/demo34_add_a_link_on_nicknames.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo34_add_a_link_on_nicknames.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> @@ -37,7 +37,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo35_shared_memory.php =================================================================== --- trunk/demo/demo35_shared_memory.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo35_shared_memory.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -66,7 +66,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> </body> Modified: trunk/demo/demo36_in_ukrainian.php =================================================================== --- trunk/demo/demo36_in_ukrainian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo36_in_ukrainian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo37_in_dutch_from_netherlands.php =================================================================== --- trunk/demo/demo37_in_dutch_from_netherlands.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo37_in_dutch_from_netherlands.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo38_in_norwegian_bokmal.php =================================================================== --- trunk/demo/demo38_in_norwegian_bokmal.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo38_in_norwegian_bokmal.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo39_in_bosnian.php =================================================================== --- trunk/demo/demo39_in_bosnian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo39_in_bosnian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo3_client.php =================================================================== --- trunk/demo/demo3_client.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo3_client.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -26,21 +26,21 @@ 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); + highlight_string($content); echo "</pre>"; $filename = dirname(__FILE__)."/demo3_config.php"; 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); + highlight_string($content); echo "</pre>"; $filename = dirname(__FILE__)."/demo3_server.php"; 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); + highlight_string($content); echo "</pre>"; ?> </body> Modified: trunk/demo/demo40_in_turkish.php =================================================================== --- trunk/demo/demo40_in_turkish.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo40_in_turkish.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo41_in_greek.php =================================================================== --- trunk/demo/demo41_in_greek.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo41_in_greek.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo42_in_chinese_from_taiwan.php =================================================================== --- trunk/demo/demo42_in_chinese_from_taiwan.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo42_in_chinese_from_taiwan.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo43_change_the_nicknames_colors.php =================================================================== --- trunk/demo/demo43_change_the_nicknames_colors.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo43_change_the_nicknames_colors.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> @@ -37,7 +37,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo44_green_theme.php =================================================================== --- trunk/demo/demo44_green_theme.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo44_green_theme.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -26,7 +26,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo45_in_bulgarian.php =================================================================== --- trunk/demo/demo45_in_bulgarian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo45_in_bulgarian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo46_in_hungarian.php =================================================================== --- trunk/demo/demo46_in_hungarian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo46_in_hungarian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo47_in_polish.php =================================================================== --- trunk/demo/demo47_in_polish.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo47_in_polish.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo48_custom_proxy.php =================================================================== --- trunk/demo/demo48_custom_proxy.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo48_custom_proxy.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -31,7 +31,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo49_msn_smiley_theme.php =================================================================== --- trunk/demo/demo49_msn_smiley_theme.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo49_msn_smiley_theme.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -30,7 +30,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo4_simulate_slow_server.php =================================================================== --- trunk/demo/demo4_simulate_slow_server.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo4_simulate_slow_server.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -32,7 +32,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo50_customized_usermetadata.php =================================================================== --- trunk/demo/demo50_customized_usermetadata.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo50_customized_usermetadata.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> @@ -39,7 +39,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo51_zilveer_theme.php =================================================================== --- trunk/demo/demo51_zilveer_theme.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo51_zilveer_theme.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -30,7 +30,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo52_in_bangla.php =================================================================== --- trunk/demo/demo52_in_bangla.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo52_in_bangla.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo53_in_armenian.php =================================================================== --- trunk/demo/demo53_in_armenian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo53_in_armenian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo54_in_esperanto.php =================================================================== --- trunk/demo/demo54_in_esperanto.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo54_in_esperanto.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo55_mysql_container.php =================================================================== --- trunk/demo/demo55_mysql_container.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo55_mysql_container.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -34,7 +34,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> </body> Modified: trunk/demo/demo56_in_romanian.php =================================================================== --- trunk/demo/demo56_in_romanian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo56_in_romanian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo57_in_korean.php =================================================================== --- trunk/demo/demo57_in_korean.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo57_in_korean.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo58_in_danish.php =================================================================== --- trunk/demo/demo58_in_danish.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo58_in_danish.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo59_in_norwegian_nynorsk.php =================================================================== --- trunk/demo/demo59_in_norwegian_nynorsk.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo59_in_norwegian_nynorsk.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo5_customized_style.php =================================================================== --- trunk/demo/demo5_customized_style.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo5_customized_style.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -36,7 +36,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> @@ -45,7 +45,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo60_in_vietnamese.php =================================================================== --- trunk/demo/demo60_in_vietnamese.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo60_in_vietnamese.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo61_in_croatian.php =================================================================== --- trunk/demo/demo61_in_croatian.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo61_in_croatian.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo62_in_belgian_dutch.php =================================================================== --- trunk/demo/demo62_in_belgian_dutch.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo62_in_belgian_dutch.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo63_in_thai.php =================================================================== --- trunk/demo/demo63_in_thai.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo63_in_thai.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -24,7 +24,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo64_in_galician.php =================================================================== --- trunk/demo/demo64_in_galician.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo64_in_galician.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -24,7 +24,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo65_metadata_and_html.php =================================================================== --- trunk/demo/demo65_metadata_and_html.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo65_metadata_and_html.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -27,7 +27,7 @@ echo "<pre style=\"margin: 0 50px 0 50px; padding: 10px; background-color: #DDD;\">"; $content = file_get_contents($filename); $content = preg_replace('/\<\?php \/\* start hide \*\/ \?\>.*?\<\?php \/\* end hide \*\/ \?\>/s','',$content); - echo htmlentities($content); + highlight_string($content); echo "</pre>"; ?> @@ -37,7 +37,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> <?php /* end hide */ ?> Modified: trunk/demo/demo6_in_french.php =================================================================== --- trunk/demo/demo6_in_french.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo6_in_french.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo7_in_english.php =================================================================== --- trunk/demo/demo7_in_english.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo7_in_english.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -28,7 +28,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo8_with_a_iso-8859-1_encoded_page.php =================================================================== --- trunk/demo/demo8_with_a_iso-8859-1_encoded_page.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo8_with_a_iso-8859-1_encoded_page.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -34,7 +34,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> Modified: trunk/demo/demo9_with_a_utf8_encoded_nickname.php =================================================================== --- trunk/demo/demo9_with_a_utf8_encoded_nickname.php 2008-03-23 19:50:24 UTC (rev 1226) +++ trunk/demo/demo9_with_a_utf8_encoded_nickname.php 2008-03-23 20:07:12 UTC (rev 1227) @@ -29,7 +29,7 @@ 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); + highlight_string($content); echo "</pre>"; ?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |