add bold for your user to js code j_stand_cont()
[brisk.git] / web / room.js
index 7874263..f3a5d88 100644 (file)
@@ -294,6 +294,9 @@ function j_stand_cont(ddata)
     if (standup_data_old == null || data.length < 4) {
         content = '<table cols="'+(data.length < 4 ? data.length : 4)+'" class="table_standup">';
         for (i = 0 ; i < data.length ; i++) {
+            if (ddata[i][1] == window.myname) {
+                ddata[i][0] |= 1;
+            }
             if ((i % 4) == 0)
                 content += '<tr>';
             content += '<td id="'+i+'" class="room_standup">';
@@ -443,6 +446,9 @@ function j_tab_cont(table_idx, data)
     var content = '';
 
     for (i = 0 ; i < data.length ; i++) {
+        if (data[i][1] == window.myname) {
+            data[i][0] |= 1;
+        }
         content += j_stand_tdcont(data[i]);
 
         content += '<br>';
@@ -504,13 +510,13 @@ function j_check_login(login, ret)
             (login[i] >= 'A' && login[i] <= 'Z')) {
             if (old_c != login[i]) {
                 old_c = login[i];
-                old_ct = 0;
+                old_ct = 1;
             }
             else {
-                if (old_ct > 3) {
+                if (old_ct > 2) {
                     // FIXME LANG
-                    ret.ret = (g_lang == 'en' ? "More than three contiguous '" + old_c + "' not allowed." :
-                               "Il nickname contiene più di tre caratteri '" + old_c + "' consecutivi.");
+                    ret.ret = (g_lang == 'en' ? "More than two contiguous '" + old_c + "' not allowed." :
+                               "Il nickname contiene più di 2 caratteri '" + old_c + "' consecutivi.");
                     return (false);
                 }
             }
@@ -639,7 +645,7 @@ function mesgtoadm_formtext_hilite(form)
 
 function j_check_email(email, ret)
 {
-    if (/^\w+([\.-]?\w+)*@\w+([\.-]?\w+)*(\.\w{2,10})+$/.test(email))
+    if (/^\w+([\.-]*\w+)*@\w+([\.-]*\w+)*(\.\w{2,10})+$/.test(email))
         return (true);
     ret.ret += (g_lang == 'en' ? "Invalid email address. " :
                 "Indirizzo e-mail non valido.");