[Phpfreechat-svn] SF.net SVN: phpfreechat: [874] trunk
Status: Beta
Brought to you by:
kerphi
|
From: <ke...@us...> - 2006-11-15 07:31:10
|
Revision: 874
http://svn.sourceforge.net/phpfreechat/?rev=874&view=rev
Author: kerphi
Date: 2006-11-14 23:30:57 -0800 (Tue, 14 Nov 2006)
Log Message:
-----------
[en] Add the word-wrap CSS3 property to replace the dirty regex code in order to cut the long words. (thanks to firebane) [15min]
[fr] Ajoute la r?\195?\168gle CSS3 word-wrap en remplacement des regex permettant de couper les mots. (merci ?\195?\160 firebane) [15min]
Modified Paths:
--------------
trunk/src/client/pfcclient.js
trunk/themes/default/style.css
Modified: trunk/src/client/pfcclient.js
===================================================================
--- trunk/src/client/pfcclient.js 2006-11-14 13:19:22 UTC (rev 873)
+++ trunk/src/client/pfcclient.js 2006-11-15 07:30:57 UTC (rev 874)
@@ -1192,6 +1192,9 @@
rx = new RegExp('(^|[ :,;])'+RegExp.escape(this.nickname)+'([ :,;]|$)','gi');
msg = msg.replace(rx, '$1<strong>'+ this.nickname +'</strong>$2');
+
+ // this piece of code is replaced by the word-wrap CSS3 rule.
+ /*
// don't allow to post words bigger than 65 caracteres
// doesn't work with crappy IE and Konqueror !
rx = new RegExp('([^ \\:\\<\\>\\/\\&\\;]{60})','ig');
@@ -1206,6 +1209,7 @@
msg = msg + ttt[i] + ' ';
}
}
+ */
return msg;
},
Modified: trunk/themes/default/style.css
===================================================================
--- trunk/themes/default/style.css 2006-11-14 13:19:22 UTC (rev 873)
+++ trunk/themes/default/style.css 2006-11-15 07:30:57 UTC (rev 874)
@@ -96,6 +96,7 @@
/* WARNING: do not fix height in % because it will display blank screens on IE6 */
/* height: 100%;*/
overflow: auto;
+ word-wrap: break-word;
}
div.pfc_online {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|