Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- var ua = navigator.userAgent.toLowerCase();
- var isGecko = (ua.indexOf("gecko") != -1);
- var isIE = ((ua.indexOf("msie") != -1) && (ua.indexOf("opera") == -1) && (ua.indexOf("webtv") == -1));
- var isNS = (ua.indexOf("netscape") != -1);
- var activpanel = 0;
- var iframeanchor;
- var iframeperse;
- function screenSize()
- {
- var w, h;
- w = (window.innerWidth) ? window.innerWidth : window.document.body.clientWidth;
- h = (window.innerHeight) ? window.innerHeight : window.document.body.clientHeight;
- return {
- w: w,
- h: h
- }
- }
- function userMenuShow(unamer, hostip, timew, _link, evt, short)
- {
- evt = evt || window.event;
- evt.cancelBubble = true;
- var url;
- if (short)
- {
- url = "http://netchat.ru/chat/menu.php?short=1&name="
- }
- else
- {
- url = "http://netchat.ru/chat/menu.php?short=0&name="
- }
- var mail = '';
- iframeanchor = _link;
- var iframe = document.getElementById(short ? "userDropDownIdshort" : "userDropDownId");
- iframeperse = iframe;
- iframe.src = url + unamer + '&hostip=' + hostip + '&timew=' + timew;
- iframe.style.display = "";
- dframe = "irc";
- userframe = gebi(dframe);
- mousey = absPosition(userframe).y;
- y = evt.clientY;
- pageyoff = (window.pageYOffset) ? window.pageYOffset : document.body.scrollTop;
- iframe.style.top = mousey + y + pageyoff + 20;
- if (mousey + y + pageyoff + iframe.offsetHeight > screenSize().h)
- {
- resoy = mousey + y + pageyoff + iframe.offsetHeight - screenSize().h;
- iframe.style.top = mousey + y + pageyoff - resoy - 40
- }
- iframe.style.left = (screenSize().w - absPosition(_link).x - iframe.offsetWidth > 0) ? absPosition(_link).x : absPosition(_link).x - iframe.offsetWidth + _link.offsetWidth;
- return false
- }
- function iframerepositiononresize()
- {
- if (!iframeperse)
- {
- return
- }
- var _link = iframeanchor;
- var iframe = iframeperse;
- iframe.style.top = absPosition(_link).y + _link.offsetHeight;
- iframe.style.left = (screenSize().w - absPosition(_link).x - iframe.offsetWidth > 0) ? absPosition(_link).x : absPosition(_link).x - iframe.offsetWidth + _link.offsetWidth
- }
- function userMenuHide()
- {
- var iframe = document.getElementById("userDropDownId");
- iframe.src = "http://netchat.ru/ajax/loading.html";
- iframe.style.display = "none";
- document.getElementById("userDropDownIdshort").style.display = "none"
- }
- function gebi(id)
- {
- return document.getElementById(id)
- }
- function screenSize()
- {
- var w, h;
- w = (window.innerWidth) ? window.innerWidth : window.document.body.clientWidth;
- h = (window.innerHeight) ? window.innerHeight : window.document.body.clientHeight;
- return {
- w: w,
- h: h
- }
- }
- function absPosition(obj)
- {
- var x = y = 0;
- while (obj)
- {
- x += obj.offsetLeft;
- y += obj.offsetTop;
- obj = obj.offsetParent
- }
- return {
- x: x,
- y: y
- }
- }
- function pageWidth()
- {
- return (window.innerWidth) ? window.innerWidth : window.document.body.clientWidth
- }
- function pageHeight()
- {
- return (window.innerHeight) ? window.innerHeight : window.document.body.clientHeight
- }
- function ts(_link, e, id, dframe)
- {
- if (!e) e = event;
- if (typeof (dframe) == 'undefined') dframe = 0;
- top.tss(e.clientX, e.clientY, dframe, id);
- return false
- }
- function tss(x, y, dframe, text)
- {
- var what = "tooltip";
- var buftt = new Array();
- buftt[1] = '1|Скрытие панели|При нажатии скрывается правая часть страницы, окно сообщений при этом увеличивается. Немного уменьшается расход трафика на обновлении списка пользователей.';
- buftt[2] = '1|Показ панели|Показывает ранее скрытую часть страницы.';
- buftt[3] = '1|Обратная связь|При нажатии Вас перекинет на страницу для связи с администрацией.';
- buftt[4] = '1|Текущее время|Текущее время.';
- buftt[5] = '1|Время в чате|Время проведенное Вами в чате.';
- buftt[6] = '1|Сейчас в чате|Количество людей, которые сейчас находятся в чате.';
- buftt[7] = '1|Обновить чат|При нажатии перезагружает окно сообщений и список пользователей. Очищает память браузера, рекомендуется использовать при частом зависании.';
- buftt[8] = '1|Идникатор связи|Если значок зеленый - связь в норме. Если мигает красным - связь с сайтом потеряна и нужно, обновить сайт или проверить свое соединение с интернетом.';
- buftt[9] = '1|Лаг|Показывает сколько прошло секунд с момента последней удачной проверки соединения.';
- buftt[10] = '1|Сервис|<b>0</b> - Вкл/Выкл игнорирования пользователя. <b>«</b> - Вставляет ник пользователя в форму отправки сообщения.';
- buftt[11] = '1|Действия с ником|Нажатие на ник пользователя позволяет отправить <b>приватное сообщение</b> пользователю. Кнопки <b>М</b>, <b>Ж</b> - Пол пользователя, при нажатии выводят информацию о нем.';
- buftt[12] = '1|Статус|Персональный статус пользователя, устанавливается пользователем.';
- buftt[13] = '1|Cкролл|Задействует скроллинг, который постоянно прокручивает окно сообщений вниз.';
- buftt[14] = '1|Приват|При включенной галочке показываются только сообщения в вашем привате, а остальные обычные фразы скрываются.';
- buftt[15] = '1|Транслит|Установливает перевод всех фраз с английской раскладки на русскую. Так, вы можете написать Vsem Privet!, а в чате появится Всем Привет!.';
- buftt[16] = '1|Звук|Озвучивает звуковые команды в чате.';
- buftt[17] = '1|Отправка|Форма для ввода сообщений и последующей их отправки.';
- buftt[18] = '1|Приват|Если указан ник значит сообщение будет отправленно ему в приват.';
- mousex = 0;
- mousey = 0;
- var outtt = buftt[text].split('|');
- if (dframe != 0)
- {
- userframe = gebi(dframe);
- mousex = absPosition(userframe).x;
- mousey = absPosition(userframe).y
- }
- pagexoff = (window.pageXOffset) ? window.pageXOffset : document.body.scrollLeft;
- pageyoff = (window.pageYOffset) ? window.pageYOffset : document.body.scrollTop;
- digix = x;
- if (gebi(what))
- {
- obj = gebi(what).style;
- if (obj)
- {
- obj.display = 'block';
- gebi(what).innerHTML = "<p style='FONT-SIZE: 10px'>" + outtt[2] + "</p>";
- if (mousex + x + pagexoff + gebi(what).offsetWidth > pageWidth())
- {
- rrraz = mousex + x + pagexoff + gebi(what).offsetWidth - pageWidth();
- obj.left = mousex + digix + pagexoff - rrraz - 10
- }
- else obj.left = (mousex + digix) + (pagexoff - 60);
- obj.top = mousey + y + pageyoff + 20;
- if (mousey + y + pageyoff + gebi(what).offsetHeight > pageHeight())
- {
- resoy = mousey + y + pageyoff + gebi(what).offsetHeight - pageHeight();
- obj.top = mousey + y + pageyoff - resoy - 30
- }
- }
- }
- return true
- }
- function tc()
- {
- obj = gebi("tooltip").style;
- if (obj) obj.display = 'none';
- return true
- }
- function kcode()
- {
- if (navigator.appName == "Netscape" || navigator.appName == "Konqueror")
- {
- return true
- }
- else
- {
- if (window.event.ctrlKey && window.event.keyCode == 87) return false
- }
- }
- document.oncontextmenu = function ()
- {
- return false
- };
- if (document.layers)
- {
- window.captureEvents(Event.MOUSEDOWN);
- window.onmousedown = function (e)
- {
- if (e.target == document) return false
- }
- }
- else
- {
- document.onmousedown = function ()
- {
- return false
- }
- }
- jsl_msg = "Не загружен чат, либо плохая связь с Интернетом. Попробуйте обновить чат.";
- function Hex(B)
- {
- Chars = "0123456789abcdef";
- return Chars.charAt(B >> 4) + Chars.charAt(B & 0x0F)
- }
- function gradtext(C1, C2, C3, Str)
- {
- function l(Str)
- {
- return Str.replace(/<[^>]+>?/g, "").replace(/&([a-z]{2,}|#\d+|#x[\da-f]{2});/gi, " ").length
- }
- function c(R, G, B, Str)
- {
- return "<font color=#" + Hex(R) + Hex(G) + Hex(B) + ">" + Str + "</font>"
- }
- function g(C1, C2, l, s)
- {
- C1 = parseInt("0x0" + C1.substr(1));
- C2 = parseInt("0x0" + C2.substr(1));
- var R1 = C1 >> 16,
- G1 = (C1 >> 8) & 0xFF,
- B1 = C1 & 0xFF;
- var R2 = C2 >> 16,
- G2 = (C2 >> 8) & 0xFF,
- B2 = C2 & 0xFF;
- var Res = "";
- var d = l - s;
- R2 -= R1;
- G2 -= G1;
- B2 -= B1;
- for (var i = 0; iS < Str.length;)
- {
- if (Str.charAt(iS) == '<')
- {
- for (var t = 0; iS < Str.length; iS++)
- {
- Res += Str.charAt(iS);
- if (Str.charAt(iS) == '>' && !t) break
- }
- iS++
- }
- else if (i != l)
- {
- var S = (Str.charAt(iS) == '&' && /^(&([a-z]{2,}|#\d+|#x[\da-f]{2});)/i.test(Str.substr(iS))) ? RegExp.$1 : Str.charAt(iS);
- Res += d ? c(R1 + i * R2 / d, G1 + i * G2 / d, B1 + i * B2 / d, S) : c(R1, G1, B1, S);
- iS += S.length;
- i++
- }
- else break
- }
- return Res
- }
- Str = Str.replace(/^\s+|\s+$/g, "");
- var iS = 0;
- var Len = l(Str);
- return C2 ? g(C1, C2, Math.floor(Len / 2), 0) + g(C2, C3, Math.round(Len / 2), 1) : g(C1, C3, Len, 1)
- }
- function gradmsg(gmnick, def)
- {
- switch (gmnick.toLowerCase())
- {
- case "робот":
- return "<span style=color:steelblue>" + def + "</span>";
- break;
- case "scumtron":
- return gradtext('#CC3333', '#993300', '#000000', def);
- break;
- case "fresh":
- return gradtext('#000066', '#bb0000', '#000077', def);
- break;
- case "плутовка":
- return gradtext('#33FF00', '#33CC00', '#0000FF', def);
- break;
- case "банди":
- return gradtext('#FF0033', '#0033FF', '#336633', def);
- break;
- default:
- return def
- }
- }
- function gradnick(gnick)
- {
- switch (gnick.toLowerCase())
- {
- case "робот":
- return "<img src=\"http://netchat.ru/i/chat/bot.gif\" width=16 height=16 border=0 alt=\"РОБОТ\"> <b style=color:steelblue>РОБОТ</b>";
- break;
- case "fresh":
- return gradtext('#336600', '#55aa00', '#88ff00', gnick);
- break;
- case "scumtron":
- return "<img src=\"http://netchat.ru/i/russia.gif\" width=15 height=10 border=0 alt=\"Россия матушка\"> <b style=color:black>Scumtron</b>";
- break;
- case "goldsteals":
- return "<img src=http://netchat.ru/chat/im/graf/elite.gif border=0 width=24 heihgt=15><b><font color=black>GolD</font><font color=#ff631f>steals</font></b>";
- break;
- case "плутовка":
- return gradtext('#0000FF', '#33CC00', '#33FF00', gnick);
- break;
- case "банди":
- return gradtext('#336633', '#0033FF', '#FF0033', gnick);
- break;
- default:
- return gnick
- }
- }
- function joinfraz(fjnick, def)
- {
- switch (fjnick.toLowerCase())
- {
- case "fresh":
- return "<b><font color=black>{@nick}</font> <font color=red> входит в чат!</font></b>";
- break;
- case "scumtron":
- return "<b><font color=black>{@nick}</font> <font color=red> входит в чат!</font></b>";
- break;
- default:
- return def
- }
- }
- function partfraz(fpnick, def)
- {
- switch (fpnick.toLowerCase())
- {
- case "fresh":
- return "<b><font color=black>{@nick}</font> <font color=red> покинул чат!</font></b>";
- break;
- case "scumtron":
- return "<b><font color=black>{@nick}</font> <font color=red> покинул чат!</font></b>";
- break;
- default:
- return def
- }
- }
- function gradst(stnick, st)
- {
- switch (stnick.toLowerCase())
- {
- case "fresh":
- return "<font style='color:steelblue;font-weight:normal;'></font>";
- break;
- case "scumtron":
- return "<font style='color:red;font-weight:normal;'>Наблюдатель ООН</font>";
- break;
- case "goldsteals":
- return "<b><font color=black>o</font><font color=red>W</font><font color=black>ner</font></b>";
- break;
- default:
- return st
- }
- }
- function gradsuper(stnick, st)
- {
- switch (stnick.toLowerCase())
- {
- case "fresh":
- return "<font style='color:steelblue;font-weight:normal;'>админ</font>";
- break;
- case "goldsteals":
- return "77777";
- break;
- default:
- return st
- }
- }
- function gradnil(linick)
- {
- switch (linick.toLowerCase())
- {
- case "робот":
- return "<b style=color:steelblue>РОБОТ</b>";
- break;
- default:
- return linick
- }
- }
- var runscrl = 1;
- var lastnick = '';
- var lastnicksend = 0;
- var onlyprivate = 0;
- var is_vik = 0;
- var tot_sm = 0;
- var tot_nicks = 0;
- var hidn = 0;
- var etmr = 0,
- efocus = 0,
- eall = 1;
- function e_focus()
- {
- efocus = 1
- }
- function e_blur()
- {
- efocus = 0
- }
- function e_up()
- {
- top.etmr = 0
- }
- function is_focus()
- {
- if (!efocus && etmr > con_str1 || etmr > con_str2) return true;
- return false
- }
- function try_focus()
- {
- if (is_focus()) set_focus()
- }
- function zero2(i)
- {
- if (i < 10) return "0" + i;
- return i
- }
- function microtime()
- {
- return (new Date()).getTime()
- }
- function unixtime()
- {
- var s = ((new Date()).getTime()).toString();
- return s.substr(0, s.length - 3)
- }
- function unset(arr, num)
- {
- var buf = new Array();
- var j = 0;
- for (i = 0; i < arr.length; i++) if (i != num) buf[j++] = arr[i];
- return buf
- }
- function getCookie(name)
- {
- var prefix = name + "=";
- var cookieStartIndex = document.cookie.indexOf(prefix);
- if (cookieStartIndex == -1) return null;
- var cookieEndIndex = document.cookie.indexOf(";", cookieStartIndex + prefix.length);
- if (cookieEndIndex == -1) cookieEndIndex = document.cookie.length;
- return unescape(document.cookie.substring(cookieStartIndex + prefix.length, cookieEndIndex))
- }
- function putCookie(n, v)
- {
- var exp = '';
- var now = new Date();
- then = now.getTime() + (365 * 24 * 60 * 60 * 1000);
- now.setTime(then);
- exp = '; expires=' + now.toGMTString();
- document.cookie = n + "=" + v + '; path=/' + exp
- }
- function nickpriv(nick)
- {
- if (nick == top.mynick) return top.chatalert("Самому себе писать запрещено.");
- var p = parent.frames.kbd.document.kbd_form;
- p.cmd.value = "N0";
- p.t1.value = nick;
- if (top.lastnick != "" && top.lastnicksend && p.msgname.value.substr(0, top.lastnick.length + 2) == top.lastnick + ": ") p.msgname.value = p.msgname.value.substr(top.lastnick.length + 2, p.msgname.value.length);
- top.set_focus()
- }
- function nickcopy(nick)
- {
- tot_nicks++;
- if (tot_nicks > 4)
- {
- var p = parent.frames.kbd.document.kbd_form;
- p.cmd.value = "N1";
- p.t1.value = "";
- p.msgname.value = "";
- tot_nicks = tot_nicks - 2;
- top.chatalert("Хватит по никам клацать!");
- return
- }
- var p = parent.frames.kbd.document.kbd_form;
- p.msgname.focus();
- p.cmd.value = "N1";
- p.t1.value = "";
- if (p.msgname.value.substring(0, 1) == "/") p.msgname.value = p.msgname.value + " " + nick + " ";
- else
- {
- if (top.lastnick != "" && top.lastnicksend && p.msgname.value == top.lastnick + ": ") p.msgname.value = "";
- p.msgname.value = nick + ': ' + p.msgname.value;
- top.lastnick = nick;
- top.lastnicksend = 0
- }
- }
- function set_focus()
- {
- var p = parent.frames.kbd;
- if (p && p.document.kbd_form)
- {
- p.focus();
- p.document.kbd_form.msgname.focus();
- p.document.kbd_form.msgname.value += ""
- }
- top.frazafocus = 1;
- return false
- }
- function sm(evt, smile)
- {
- var evt = parent.frames.irc.event || evt;
- tot_sm++;
- if (tot_sm > 4 && s3 < 300)
- {
- var p = parent.frames.kbd.document.kbd_form;
- p.cmd.value = "N1";
- p.t1.value = "";
- p.msgname.value = "";
- tot_sm = 0;
- top.chatalert("Установлен лимит: 4 смайлика на сообщение!");
- return
- }
- if (evt.shiftKey)
- {
- if (top.auth == 0)
- {
- top.chatalert("Вы не зарегистрированы и по этому не можете добавить смайлы в личную галерею!");
- return
- }
- exts = smile.split('/');
- if (exts[0] == "1")
- {
- top.chatalert("Смайлы из панели добавлять нельзя!");
- return
- }
- parent.frames.more.location.href = 'http://' + wwwhost + '/' + wwp + 'mysmile.php?smile=' + smile + top.sess;
- return
- }
- var p = parent.kbd.document.kbd_form;
- p.msgname.value = p.msgname.value + " :" + smile + ": ";
- p.msgname.focus()
- }
- var smmode = 0;
- function sm2sh()
- {
- pnshow();
- top.smmode ^= 1;
- if (top.smv == 0 || top.smv == null)
- {
- rrr = '32';
- top.smv = 1
- }
- else
- {
- rrr = '0';
- top.smv = 0
- }
- document.getElementById('main2').rows = '22,*,' + rrr;
- s_main();
- set_focus()
- }
- var _pnshow = 0;
- function pnshow()
- {
- if (_pnshow || !parent.frames.head.document.getElementById("pnsm")) return;
- _pnshow = 1;
- for (i = 0; i < smhl.length; i++) parent.frames.head.document.getElementById("pnsm").innerHTML += "<a href='javascript:top.sm(\"1/" + smhl[i] + "\")'><img src=im/sm1/" + smhl[i] + ".gif border=0></a>"
- }
- _fsc = 0;
- function fsc()
- {
- _fsc ^= 1;
- document.getElementById('mainframe').rows = _fsc ? '14,*,' + top.height2 : top.height + ',*,' + top.height2;
- parent.secondframe.cols = _fsc ? '*,0' : '*,300';
- if (!_fsc) smmode = 0;
- s_main();
- set_focus()
- }
- function clms()
- {
- tot_nicks = 0;
- tot_sm = 0;
- var p = parent.frames.kbd.document.kbd_form;
- p.cmd.value = "N1";
- p.t1.value = "";
- p.msgname.value = "";
- setTimeout("top.set_focus()", 10)
- }
- function scroll_switch()
- {
- top.runscrl ^= 1;
- var p = parent.frames.more.document.more_form;
- if (p && p.scrl) p.scrl.checked = top.runscrl;
- scroll_uservars()
- }
- function scroll_to(value)
- {
- top.runscrl = value;
- var p = parent.frames.more.document.more_form;
- if (p && p.scrl) p.scrl.checked = top.runscrl;
- scroll_uservars()
- }
- function scroll_uservars()
- {
- if (top.runscrl == 1)
- {
- top.userflag = 0;
- top.downflag = 0
- }
- else
- {
- top.userflag = 1;
- top.downflag = 1
- }
- }
- function set_quit()
- {
- var p = parent.frames.kbd.document.kbd_form;
- p.cmd.value = "N3";
- p.msgname.value = "/quit";
- p.target = 'kbdpost';
- p.submit()
- }
- function setignore(nick)
- {
- var p = parent.frames.kbd.document.cmdform;
- if (nick == top.mynick)
- {
- top.chatalert("Невозможно игнорировать самого себя.");
- return
- }
- p.cmd.value = "ignore";
- p.cmd1.value = nick;
- p.submit()
- }
- function wcopy()
- {
- if (window.status.substring(0, top.copy.length) != top.copy)
- {
- window.status = top.copy
- }
- setTimeout("wcopy()", 5000)
- }
- setTimeout("wcopy()", 100);
- function ln0()
- {
- window.status = copy;
- return true
- }
- function ln1(n)
- {
- window.status = 'Написать сообщение пользователю ' + n;
- return true
- }
- function ln2(n)
- {
- window.status = 'Написать приватное сообщение пользователю ' + n;
- return true
- }
- var ul_tid = 0,
- ul_loaded = 0,
- ul_tid2 = 0,
- ul_last = 0,
- ul_qty = 0;
- var user = new Array(),
- userinfo = new Array();
- function ul_cron()
- {
- userlist_show();
- if (ul_tid) clearTimeout(ul_tid);
- ul_tid = 0;
- if (!ul_loaded) ul_tid = setTimeout("ul_cron()", 1000)
- }
- function userlist_show()
- {
- if (top.ul_tid2)
- {
- clearTimeout(top.ul_tid2);
- top.ul_tid2 = setTimeout("userlist_show_go()", 1000);
- return
- }
- top.ul_tid2 = setTimeout("userlist_show_go()", 1000)
- }
- function userlist_show_go()
- {
- if (!parent.list.document.getElementById("htmllist") || !parent.list)
- {
- if (!ul_tid) ul_tid = setTimeout("ul_cron()", 2000);
- ul_loaded = 0;
- return
- }
- if (ul_tid) clearTimeout(ul_tid);
- ul_loaded = 1;
- ul_tid = 0;
- var buf = "",
- i, v, u, info, st, html, classlist, time1 = microtime(),
- l = user.length,
- classtlistend;
- for (i = 0; i < l; i++)
- {
- v = user[i];
- u = userinfo[i];
- classlist = "class='statlist' href='#moder' onclick=\"return top.chatModer(this, '" + v[0] + "')\">";
- if (!v[5] && v[1] == 0)
- {
- classlist = "class='statlist' style='text-decoration:none;color:#666699' onclick='return false;'>";
- if (v[4] == 1) info = "(" + top.ul_male + ")";
- else if (v[4] == 2) info = "(" + top.ul_female + ")";
- else info = top.ul_noauth
- }
- else if (v[1] > 0) info = v[1];
- else if (v[4] == 1) info = top.ul_male;
- else if (v[4] == 2) info = top.ul_female;
- else
- {
- classlist = "class='statlist' style='text-decoration:none;color:#666699' onclick='return false;'>";
- if (v[4] == 1) info = "(" + top.ul_male + ")";
- else if (v[4] == 2) info = "(" + top.ul_female + ")";
- else info = top.ul_noauth
- }
- info = gradsuper(v[0], info);
- if (u[1] == 0) st = "<font class=clistc0>" + top.ul_msg[1] + "</font>";
- else if (u[1] == 2) st = "<font class=clistc2>" + top.ul_msg[0] + "</font>";
- else if (v[10] != "")
- {
- st = "<a href='#' class=clistaway onMouseOver='window.status=\"Пользователь отсуствует, причина: \"+top.user[" + i + "][10]; return 1' onMouseOut='window.status=top.copy;return 1' title='" + v[10] + "'>" + top.ul_msg[2] + "</a>"
- }
- else if (u[3] != "") st = "<font class=clistaway>" + u[3] + "</font>";
- else if (v[8].length < 16) st = v[8];
- else
- {
- st = "<font class=clist onMouseOver='window.status=\"Пользователь отсуствует, причина: \"+top.user[" + i + "][8]; return 1' onMouseOut='window.status=top.copy;return 1' title='" + v[8] + "'>" + v[8].substr(0, 13) + "...</font>"
- }
- if (lite_version == 1)
- {
- st = gradst(v[0], st)
- }
- if (lite_version == 1)
- {
- nickita = gradnil(v[0])
- }
- if (v[0] == top.mynick)
- {
- html = top.ul_me(i % 2 ? top.userlist_c2 : top.userlist_c1, v[3] != "" ? " 'www ip: " + v[2] + "www host:" + v[3] + "Real host:" + u[2] + "UserNum:" + v[9] + "'" : "'Кнопка-игнора'", v[3] != "" ? "<td class=s8 width='1%'> <a onMouseOver='window.status=\"Забанить себя.\"; return 1' onMouseOut='window.status=top.copy;return 1' class=s8 href=javascript:top.ban('" + v[0] + "','" + v[3] + "')>[B]</a> </td>" : "", v[0], " <a onMouseOver='window.status=\"Информация о себе\"; return 1' onMouseOut='window.status=top.copy;return 1' " + classlist + "" + info + "</a>", st, nickita)
- }
- else
- {
- var lnewnicka;
- if (nickita.length > top.userlist_long)
- {
- if (v[4] == 1) lnewnicka = "nicklist_long_man";
- else if (v[4] == 2) lnewnicka = "nicklist_long_woman";
- else lnewnicka = "nicklist_long"
- }
- else
- {
- if (v[4] == 1) lnewnicka = "nicklist_man";
- else if (v[4] == 2) lnewnicka = "nicklist_woman";
- else lnewnicka = "nicklist"
- }
- html = top.ul_all(i % 2 ? top.userlist_c2 : top.userlist_c1, i, v[0], u[4] ? "<span class=myignor style='color:#ee0000;text-decoration:none' onMouseOver='window.status=\"Снять игнор с пользователя " + v[0] + ".\"; return 1' onMouseOut='window.status=top.copy;return 1'>Ø</span> " : "<span class=myignor style='color:#000000;text-decoration:none' onMouseOver='window.status=\"Поставить игнор на пользователя " + v[0] + ".\"; return 1' onMouseOut='window.status=top.copy;return 1'>Ο</span> ", v[3] != "" ? " 'www ip: " + v[2] + "www host:" + v[3] + "Real host:" + u[2] + "UserNum:" + v[9] + "'" : "'Кнопка-игнора'", v[3] != "" ? "<td class=s8 width='1%'> <a class=s8 href=javascript:top.ban('" + v[0] + "','" + v[3] + "') onMouseOver='window.status=\"Забанить пользователя " + v[0] + ".\"; return 1' onMouseOut='window.status=top.copy;return 1'>[B]</a> </td>" : "", lnewnicka, " <a onMouseOver='window.status=\"Информация о пользователе: " + v[0] + "\"; return 1' onMouseOut='window.status=top.copy;return 1' " + classlist + "" + info + "</a>", st, nickita)
- }
- buf = buf + html
- }
- parent.list.document.getElementById("htmllist").innerHTML = "<table width=100% border=0 cellspacing=0 cellpadding=1><TBODY>" + buf + "</TBODY></table>";
- parent.list.document.getElementById("htmlcount").innerHTML = user.length;
- top.ul_qty++;
- top.ul_last = top.unixtime()
- }
- var ul_idlefirst = 0;
- function userlist_idle(checklast)
- {
- var need = 0,
- time = unixtime() - away_time,
- now = unixtime(),
- ofs, i;
- if (away_time == 0) return;
- if (user && (ul_idlefirst == 0 || !checklast || checklast && now - top.ul_last >= 60))
- {
- for (i = 0; i < user.length; i++)
- {
- if (user[i][11] < time)
- {
- ofs = Math.floor((now - user[i][11]) / 60);
- if (away_show)
- {
- if (ofs < 60) userinfo[i][3] = ul_msg[3] + " " + zero2(ofs) + " " + ul_msg[4];
- else if (ofs < 600) userinfo[i][3] = ul_msg[3] + " " + Math.floor(ofs / 60) + ul_msg[6] + ":" + zero2(ofs % 60) + ul_msg[5];
- else if (ofs < 5940) userinfo[i][3] = ul_msg[3] + " " + Math.floor(ofs / 60) + ul_msg[7];
- else userinfo[i][3] = ul_msg[3] + " " + zero2(Math.floor(ofs / 1440)) + " " + ul_msg[8]
- }
- else userinfo[i][3] = ul_msg[3];
- need = 1
- }
- else userinfo[i][3] = ""
- }
- if (need)
- {
- if (sortnicks == 5) userlist_sort();
- userlist_show();
- ul_idlefirst = 1
- }
- }
- setTimeout("userlist_idle(1)", 28000)
- }
- setTimeout("userlist_idle(0)", 15000);
- function nick2num(nick)
- {
- return user2num(nick)
- }
- function user2num(nick)
- {
- for (var i = 0; i < top.user.length; i++) if (top.user[i][0] == nick) return i;
- return -1
- }
- function userlist_sort()
- {
- var tmp = new Array(),
- user2 = new Array(),
- userinfo2 = new Array(),
- n, num, i, i2;
- if (top.user.length == 0) return;
- switch (top.sortnicks)
- {
- case 1:
- for (i = 0; i < top.user.length; i++) tmp[i] = top.userinfo[i][0] + " :" + i;
- break;
- case 2:
- for (i = 0; i < top.user.length; i++) tmp[i] = (top.user[i][4] == 0 ? "3" : top.user[i][4]) + top.userinfo[i][0] + " :" + i;
- break;
- case 3:
- for (i = 0; i < top.user.length; i++)
- {
- if (top.user[i][5])
- {
- switch (top.user[i][4])
- {
- case 0:
- tmp[i] = "2" + top.userinfo[i][0] + " :" + i;
- break;
- case 1:
- tmp[i] = "1" + top.userinfo[i][0] + " :" + i;
- break;
- case 2:
- tmp[i] = "0" + top.userinfo[i][0] + " :" + i;
- break
- }
- }
- else
- {
- tmp[i] = "2" + top.userinfo[i][0] + " :" + i
- }
- }
- break;
- case 4:
- for (i = 0; i < top.user.length; i++) tmp[i] = top.user[i][14] + " :" + i;
- break;
- case 5:
- for (i = 0; i < top.user.length; i++)
- {
- tmp[i] = top.user[i][11] + " :" + i
- }
- break
- }
- tmp = tmp.sort();
- for (i = 0; i < tmp.length; i++)
- {
- n = tmp[i].indexOf(" :");
- if (n == -1)
- {
- return
- }
- num = tmp[i].substr(n + 2, 10);
- if (top.sortnicks != 5) i2 = i;
- else i2 = tmp.length - i - 1;
- user2[i2] = top.user[num];
- userinfo2[i2] = top.userinfo[num]
- }
- top.user = user2;
- top.userinfo = userinfo2
- }
- var codepage1 = "абвгдежзийклмнопрстуфхцчшщъыьэюя";
- var codepage2 = "АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯ";
- var engcode1 = "qwertyuiopasdfghjklzxcvbnm";
- var engcode2 = "QWERTYUIOPASDFGHJKLZXCVBNM";
- function str2chr(str, maxlength)
- {
- var i, v, n, c, buf = "";
- if (!maxlength) maxlength = str.length;
- for (i = 0; i < str.length && i < maxlength; i++)
- {
- v = str.substr(i, 1);
- if (v == 'Ё' || v == 'ё') v = 'е';
- n = codepage2.indexOf(v);
- if (n != -1) v = codepage1.substr(n, 1);
- n = codepage1.indexOf(v);
- if (n == -1)
- {
- c = v.charCodeAt();
- if (c > 255) c = 255
- }
- else c = 224 + n;
- if (c >= 0x41 && c <= 0x5a) c += 0x20;
- buf = buf + c.toString(16)
- }
- return buf
- }
- function st(nick)
- {
- return 'Вставить ник ' + nick + ' в поле для ввода сообщений.'
- }
- function gocmd(a, b, c)
- {
- var tt = parent.frames["kbd"].document;
- if (tt && tt.cmdform.cmd)
- {
- tt.cmdform.cmd.value = a;
- tt.cmdform.cmd1.value = b;
- tt.cmdform.cmd2.value = c;
- tt.cmdform.submit()
- }
- }
- function url(urlgo, md5)
- {
- var winname = "url_" + ((Math.round(Math.random() * 100000)).toString());
- var ans = window.confirm("Открыть адресс?");
- if (ans)
- {
- parent.frames.kbd.document.kbd_form.msgname.focus();
- window.open("http://" + top.http_host + "/" + top.wwp + "redirect_from_cpsr.php?jsclose=1&url=" + escape(urlgo) + "&md5=" + md5, winname, "toolbar=1,location=1,directories=0,status=1,menubar=1,scrollbars=1,resizable=1")
- }
- }
- function msgurl(urlgo, md5, urlshow)
- {
- var xurl = urlgo;
- var url = urlshow;
- var urlshow1 = 'сайт';
- if (urlgo.indexOf('.gif') > 10 || urlgo.indexOf('.jpg') > 10 || urlgo.indexOf('.jpeg') > 10 || urlgo.indexOf('.bmp') > 10 || urlgo.indexOf('.png') > 10) urlshow1 = 'картинка';
- else if (urlgo.indexOf('.html') > 10 || urlgo.indexOf('.htm') > 10 || urlgo.indexOf('.php') > 10) urlshow1 = 'страница';
- else if (urlgo.indexOf('.swf') > 10) urlshow1 = 'флешка';
- if (urlgo.indexOf('http://netchat.ru/forum') >= 0) urlshow1 = 'форум';
- else if (urlgo.indexOf('netchat.ru/forum') >= 0) urlshow1 = 'форум';
- return "<nobr><a class=url title='Открыть ссылку в новом окне' href='" + urlgo + "' target=kbdpost onclick=\"top.url('" + xurl + "','" + md5 + "');return false;\">" + urlshow1 + "</a></nobr>"
- }
- function s_main()
- {
- parent.frames.irc.scroll(1, 1000000)
- }
- function myinfo(ni)
- {
- if (navigator.appName == "Netscape")
- {
- wopen("cmd.php?c=info&jsclose=1&focus=1&ni=" + ni + "&" + top.asess);
- return false
- }
- if (parent.frames.list.event.shiftKey && s3 > 900) wopen("login.php?c=setup&ni=" + ni + "&jsclose=1" + top.asess);
- else wopen("cmd.php?c=info&jsclose=1&focus=1&ni=" + ni + "&" + top.asess);
- return false
- }
- function refresh(url)
- {
- document.write("<head><META HTTP-EQUIV='Refresh' CONTENT='0;url=" + url + "'></head>")
- }
- function wopen(url, n, x, y)
- {
- if (typeof (x) == 'undefined' || x == 0) x = 500;
- if (typeof (y) == 'undefined' || y == 0) y = 600;
- if (typeof (n) == 'undefined' || n == '') n = "rnd" + (Math.round(Math.random() * 100000)).toString();
- return top.open(url, n, "toolbar=0,location=0,directories=0,status=1,menubar=0,scrollbars=1,resizable=1,width=" + x + ",height=" + y)
- }
- function mopen(url, x, y, xpos, ypos)
- {
- if (typeof (x) == 'undefined') x = Math.round(screen.width / 1.3);
- if (typeof (y) == 'undefined') y = Math.round(screen.height / 1.3);
- if (typeof (xpos) == 'undefined') xpos = Math.round((screen.width - x) / 2);
- if (typeof (ypos) == 'undefined') ypos = Math.round((screen.height - y) / 2);
- var win = window.showModalDialog(url, "", "dialogHeight: " + y + "px; dialogWidth: " + x + "px; dialogTop: " + ypos + "px; dialogLeft: " + xpos + "px; edge: Raised; center: No; help: No; resizable: Yes; status: Yes;");
- return win
- }
- var close_window = 1;
- function browser_close()
- {
- var w = window.open("", "brclose", "toolbar=0,location=0,directories=0,status=0,menubar=0," + "scrollbars=0,resizable=0,width=200,height=70");
- w.document.write("<body bgcolor='#333366' text='#ffffff'><nobr><font face=arial>" + "<center><font style='font:19px Arial Black;color:#ffff77'>Выход из чата...</font><br>" + "Пожалуйста, подождите<br>несколько секунд")
- }
- function clicksmile(name)
- {
- var url = "smile.php?name=" + name + top.asess;
- gebi("more").src = url;
- return false
- }
- top.ircconnetstatus = 0;
- top.ircconnettime = 0;
- function lostircconnect()
- {
- top.ircconnetstatus = 2;
- top.ircconnettime = 0;
- lagcontrol2()
- }
- function lagcontrol()
- {
- setTimeout("top.lagcontrol()", 1000);
- var l = parent.frames.list;
- if (l && l.document.getElementById("tdirc") && l.document.getElementById("laglamp"))
- {
- if (top.rirclist > -1) l.document.getElementById("tdirc").innerHTML = top.rirclist;
- else l.document.getElementById("tdirc").value = "?";
- if (top.rirclist > top.con_str4)
- {
- l.document.getElementById("tdirc").style.backgroundColor = (top.rirclist % 2 ? top.fhead_cblink1 : top.fhead_cblink2);
- l.document.getElementById("laglamp").style.color = (top.rirclist % 2 ? top.fhead_cblink1 : top.fhead_cblink2)
- }
- else
- {
- l.document.getElementById("tdirc").style.backgroundColor = '#ffe1ab';
- l.document.getElementById("laglamp").style.color = '#0c822d'
- }
- }
- }
- cook_swf = getCookie("swf_disable");
- if (!cook_swf || cook_swf == '') cook_swf = 1;
- function lagcontrol3()
- {
- top.ircconnettime = top.ircconnettime + 1;
- setTimeout("top.lagcontrol3()", 1000)
- }
- top.lagcontrol3();
- rirclist = -30;
- function firclist()
- {
- rirclist++;
- etmr++;
- var b = 'http://' + http_host + '/' + wwp + url_irc + '?' + asess;
- if (rirclist >= con_str5 && (rirclist - con_str5) % con_str6 == 0)
- {
- parent.frames.irc.location.href = b
- }
- if (rirclist >= con_str7 + 30)
- {
- top.chatalert("Связь с сайтом потеряна. Нужно, обновить сайт или проверить свое соединение с интернетом.");
- top.location.href = 'http://' + http_host + '/' + wwp + '?' + asess;
- return false
- }
- setTimeout("firclist()", 1000)
- }
- top.firclist();
- nullframe = 0;
- function fnullframe()
- {
- nullframe++;
- if (nullframe >= top.tframe1 && (nullframe - top.tframe1) % top.tframe2 == 0)
- {
- parent.kbdnull.location.href = 'http://' + http_host + '/' + wwp + 'frame_kbdnull.php?' + asess + '&rnd=' + Math.random()
- }
- if (top.nullframe >= top.tframedie + 30)
- {
- top.chatalert("Связь с сайтом потеряна. Нужно, обновить сайт или проверить свое соединение с интернетом.");
- top.location.href = 'http://' + top.http_host + '/' + top.wwp + '?' + top.asess;
- return false
- }
- setTimeout("fnullframe()", 1000)
- }
- top.fnullframe();
- var winban = 0;
- function ban(nick, host)
- {
- if (winban && !winban.closed)
- {
- winban.window.close()
- }
- winban = window.open("http://" + top.http_host + "/" + top.wwp + top.url_cmd + "?" + top.asess + "jsclose=1&c=banwindow&ni=" + nick + "&host=" + host, "winban", "toolbar=0,location=0,directories=0,status=1,menubar=0,scrollbars=1,resizable=1,width=600,height=430")
- }
- var winbanlist = 0;
- function banlist()
- {
- if (winbanlist && !winbanlist.closed)
- {
- winbanlist.window.close()
- }
- winbanlist = window.open("http://" + top.http_host + "/" + top.wwp + top.url_cmd + "?" + top.asess + "jsclose=1&c=banlist", "banlist", "toolbar=0,location=0,directories=0,status=1,menubar=0,scrollbars=1,resizable=1,width=700,height=500")
- }
- function sinit()
- {
- userflag = 0;
- isdown = 0;
- downflag = 1;
- squickdown = 0;
- runscrl2 = 1;
- oldpostop = -1
- }
- sinit();
- ignore_sevent = 0;
- ignore_sone = 0;
- tmr_scron = 0;
- sevent_cnt = 0;
- mousedown = 0;
- startevent = 0;
- emsg = [];
- emsg1 = 0;
- emsg2 = 0;
- gcdx = 0;
- setTimeout("top.squickdown=1;", 20000);
- function irc_sevent()
- {
- top.sevent_cnt++;
- var p = parent.frames.irc.document.body;
- var pos = p.scrollHeight - p.clientHeight - p.scrollTop;
- if (pos < 2)
- {
- top.downflag = 1;
- top.userflag = 0;
- top.oldpostop = p.scrollTop;
- return
- }
- if (pos < 300)
- {
- top.downflag = 0;
- top.userflag = 0;
- top.oldpostop = p.scrollTop;
- return
- }
- if (!top.ignore_sevent && top.oldpostop - 50 > p.scrollTop)
- {
- top.userflag = 1;
- top.downflag = 0
- }
- top.oldpostop = p.scrollTop
- }
- function irc_s()
- {
- var p = parent.frames.irc.document.body;
- var pos = p.scrollHeight - p.clientHeight - p.scrollTop
- }
- function irc_scron()
- {
- try
- {
- var p = parent.frames.irc.document.body;
- var pos = p.scrollHeight - p.clientHeight - p.scrollTop;
- if (pos < 2)
- {
- top.downflag = 1;
- top.userflag = 0
- }
- if (top.runscrl && top.runscrl2 && (top.userflag == 0 && top.downflag == 1 || pos < 300))
- {
- parent.frames.irc.scrollBy(-1, top.scrolldown)
- }
- }
- catch (_err)
- {}
- }
- function irc_mouseup()
- {
- top.mousedown = 0;
- return true
- }
- function irc_mousedown()
- {
- top.mousedown = 1;
- setTimeout("top.mousedown=0", 500);
- return true
- }
- ircconnettime = 0;
- ircconnetstatus = 0;
- function load_irc()
- {
- top.ircconnettime = 0;
- top.ircconnetstatus = 1
- }
- function unload_irc()
- {
- setTimeout("top.lostircconnect();", 2000)
- }
- function mydate(time)
- {
- var str = "",
- d, m_hh, m_mm, m_ss;
- if (top.timeshow == 0) return "";
- if (!time)
- {
- str = "??:??:??"
- }
- else
- {
- if (parent.timetype == 1) d = new Date(time * 1000 - (parent.timezone * 1000));
- if (parent.timetype == 0) d = new Date(time * 1000 + new Date().getTimezoneOffset() - (parent.timezone * 1000));
- if (parent.timetype == 2) d = new Date(time * 1000 + new Date().getTimezoneOffset() - (parent.timezone * 1000) - parent.timediff * 1000);
- m_hh = (d.getHours() < 10 ? "0" + d.getHours() : d.getHours());
- m_mm = (d.getMinutes() < 10 ? "0" + d.getMinutes() : d.getMinutes());
- m_ss = (d.getSeconds() < 10 ? "0" + d.getSeconds() : d.getSeconds());
- if (parent.timeshow == 1) str = m_hh + ":" + m_mm + ":" + m_ss;
- if (parent.timeshow == 2) str = m_hh + ":" + m_mm + ":" + m_ss
- }
- return "<font class=time onclick=\"parent.cptime('" + str + "')\">[" + str + "] </font>"
- }
- function cptime(str)
- {
- var p = parent.kbd.document.kbd_form.msgname;
- parent.kbd.document.kbd_form.msgname.focus();
- if (p.value.substr(p.value.length - 1, 1) != " ") p.value += " ";
- p.value += str;
- p.value += " "
- }
- function bye(msg)
- {
- setTimeout("bye2()", 1000);
- parent.frames.irc.document.write("<hr size=1 noshade><center><font color=red><b>сервер завершает соединение</b></font></center><hr size=1 noshade>");
- top.rirclist = 0;
- parent.frames.irc.scroll(1, 1000000);
- top.byemsg = msg
- }
- var byemsg = new String("");
- function bye2()
- {
- top.chatalert(top.byemsg);
- setTimeout("top.location.href='http://'+top.http_host+':'+top.httpport+'/'+top.wwp+'?goodbye=1'+top.asess;", 5000)
- }
- function isset(x)
- {
- if (!x) return 0;
- if (x.length == 0) return 0;
- return 1
- }
- function unixtime()
- {
- var s = ((new Date()).getTime()).toString();
- return s.substr(0, s.length - 3)
- }
- function reloadfirc()
- {
- gebi('irc').src = 'http://netchat.ru/chat/firc.php?&PHPSESSID=f6aeb848d082140f500bbae2e396c8e2&'
- }
- function _in(func, time, host, nick, css, nickhtml, p1, p2, p3, p4, p5, p6)
- {
- var nf, nw, ns, nct, ncf, tf, tw, ts, tct, tcf, foundnick = 0;
- top.gcdx++;
- if (top.gcdx > 1000)
- {
- top.chatalert("Внимание накопилось слишком большое количество сообщений в Вашем окне.<br>Это может повлечть лаги и торможение браузера.<br>Рекомендуется обновить окно сообщений.<br><br><center><a onclick='top.reloadfirc(); return false;'href='#'>Обновить окно</a> | <a onclick='top.hidechatalert(); return false;' href='#'>Закрыть</a></center>");
- top.gcdx = 0
- }
- if (css == "") css = "|||||||||";
- css = css.split("|");
- if (css.length != 10) css = "|||||||||".split("|");
- nf = (!isset(css[0]) ? top.defnick_f : top.listmain_f[css[0]]);
- nw = (!isset(css[1]) ? top.defnick_w : top.listmain_w[css[1]]);
- ns = (!isset(css[2]) ? top.defnick_s : css[2] + "pt");
- nct = (!isset(css[3]) ? top.defnick_ct : top.listnick_ct[css[3]]);
- ncf = (!isset(css[4]) ? top.defnick_cf : top.listnick_cf[css[4]]);
- tf = (!isset(css[5]) ? top.deftext_f : top.listmain_f[css[5]]);
- tw = (!isset(css[6]) ? top.deftext_w : top.listmain_w[css[6]]);
- ts = (!isset(css[7]) ? top.deftext_s : css[7] + "pt");
- tct = (!isset(css[8]) ? top.deftext_ct : top.listtext_ct[css[8]]);
- tcf = (!isset(css[9]) ? top.deftext_cf : top.listtext_cf[css[9]]);
- if (top.mynick != nick)
- {
- if (top.ignore_nicks)
- {
- nct = top.defnick_ct;
- ncf = top.defnick_cf
- }
- if (top.ignore_texts)
- {
- tct = top.deftext_ct;
- tcf = top.deftext_cf
- }
- if (top.ignore_fonts)
- {
- nf = top.defnick_f;
- nw = top.defnick_w;
- ns = top.defnick_s;
- tf = top.deftext_f;
- tw = top.deftext_w;
- ts = top.deftext_s
- }
- }
- css2 = nf + "|" + nw + "|" + ns + "|" + nct + "|" + ncf + "|" + tf + "|" + tw + "|" + ts + "|" + tct + "|" + tcf;
- css = css2.split("|");
- var x = p1.toLowerCase().replace(/<\/?.+?>/g, ' '),
- y = mynick.toLowerCase();
- if (nick != mynick && (x.indexOf(y + ":") > -1 || x.indexOf(" " + y) > -1 || x.indexOf(y + " ") > -1 || x.indexOf(y + ",") > -1 || x.indexOf(y + ".") > -1 || x.indexOf(y + "?") > -1 || x.indexOf('<' + y + '>') > -1 || x == y)) foundnick = 1;
- if (!eventsgo) startevent = 0;
- var time_wins = time;
- switch (func)
- {
- case "q_privpost":
- top.tot_nicks = 0;
- if (top.cook_swf == 1) p2 = p2.replace("embed ", "xembed ");
- if (lite_version == 1) p2 = gradmsg(nick, p2);
- _out('00B800', css, time, top.timeshow_priv, "<a style=\"cursor: pointer; cursor: hand;\" onClick=\"javascript:top.nickpriv('" + p1 + "')\" onMouseOver=\"window.status='Послать сообщение в приват, его получит только пользователь " + p1 + "'; top.mnick='" + p1 + "'; top.select=1; return true;\" onMouseClick=\"window.status='" + top.copy + "'; top.select=1; return true\" onMouseOut=\"window.status='" + top.copy + "'; top.select=2;\" target=kbdpost><font class=privpost1 color=black> Лично для <b><font class=privpost2>" + p1 + "</font>:</b> </font></a><a onclick=\"top.userMenuShow('" + nick + "','" + host + "','" + time_wins + "',this, event,0); return false;\" style=\"cursor: pointer; cursor: hand;\" target=\"_blank\"><img border=0 src=\"http://help.mail.ru/js/user_arrow_pas.gif\" width=\"13\" height=\"13\" alt=\"Меню пользователя\" title=\"Меню пользователя\" align=\"absbottom\"></a>" + nbsp() + "<span class=msg " + textcss(css) + " onMouseOver=\"top.mnick='" + nick + "'; top.timeids='" + time_wins + "'; top.select=3; return true;\" onMouseClick=\"top.select=3; top.mnick='" + nick + "'; top.timeids='" + time_wins + "'; return true;\" onMouseOut=\"top.select=2;\"> " + p2 + "</span>");
- updateidle(nick, time);
- break;
- case "q_privget":
- if (top.cook_swf == 1) p2 = p2.replace("embed ", "xembed ");
- if (lite_version == 1) p2 = gradmsg(nick, p2);
- _out('FF3300', css, time, top.timeshow_priv, "<a style=\"cursor: pointer; cursor: hand;\" onClick=\"javascript:top.nickpriv('" + p1 + "')\" onMouseOver=\"window.status='Послать сообщение в приват, его получит только пользователь " + p1 + "'; top.mnick='" + nick + "'; top.mhost='" + host + "'; top.select=1; return true;\" onMouseClick=\"window.status='" + top.copy + "'; top.select=1; return true\" onMouseOut=\"window.status='" + top.copy + "'; top.select=2;\" target=kbdpost><font class=privget1> Лично от <b><font class=privget2>" + nick + "</font>:</b> </font></a><a onclick=\"top.userMenuShow('" + nick + "','" + host + "','" + time_wins + "',this, event,0); return false;\" style=\"cursor: pointer; cursor: hand;\" target=\"_blank\"><img border=0 src=\"http://help.mail.ru/js/user_arrow_pas.gif\" width=\"13\" height=\"13\" alt=\"Меню пользователя\" title=\"Меню пользователя\" align=\"absbottom\"></a>" + nbsp() + "<span id=" + time_wins + " class=msg " + textcss(css) + " onMouseOver=\"top.mnick='" + nick + "'; top.timeids='" + time_wins + "'; top.select=3; return true;\" onMouseClick=\"top.select=3; top.mnick='" + nick + "'; top.timeids='" + time_wins + "'; return true;\" onMouseOut=\"top.select=2;\"> " + p2 + "</span>");
- updateidle(p1, time);
- break;
- case "q_allmsg":
- top.tot_nicks = 0;
- mcol = "AAAAAA";
- if (top.cook_swf == 1) p1 = p1.replace("embed ", "xembed ");
- if (nick == top.mynick)
- {
- css = replace_mymsg(css);
- mcol = "00B800"
- }
- else if (foundnick)
- {
- css = replace_msgforme(css);
- mcol = "FF3300"
- }
- if (top.onlyprivate && !foundnick && nick != top.mynick) break;
- if (lite_version == 1) p1 = gradmsg(nick, p1);
- _out(mcol, css, time, top.timeshow_msg, outnick(host, nick, nickhtml, "nick", css, 1) + nbsp() + "<a onclick=\"top.userMenuShow('" + nick + "','" + host + "','" + time_wins + "',this, event,0); return false;\" style=\"cursor: pointer; cursor: hand;\" target=\"_blank\"><img border=0 src=\"http://help.mail.ru/js/user_arrow_pas.gif\" width=\"13\" height=\"13\" alt=\"Меню пользователя\" title=\"Меню пользователя\" align=\"absbottom\"></a>" + nbsp() + "<span id=" + time_wins + " class=msg " + textcss(css) + " onMouseOver=\"top.mnick='" + nick + "'; top.timeids='" + time_wins + "'; top.select=3; return true;\" onMouseClick=\"top.select=3; top.mnick='" + nick + "'; top.timeids='" + time_wins + "'; return true;\" onMouseOut=\"top.select=2;\">" + p1 + "</span>");
- updateidle(nick, time);
- break;
- case "q_allmsgme":
- mcol = "AAAAAA";
- if (top.cook_swf == 1) p1 = p1.replace("embed ", "xembed ");
- if (nick == top.mynick)
- {
- css = replace_mymsg(css);
- mcol = "00B800"
- }
- else if (foundnick)
- {
- css = replace_msgforme(css);
- mcol = "FF3300"
- }
- if (top.onlyprivate && !foundnick && nick != top.mynick) break;
- css[4] = css[9];
- _out(mcol, css, time, top.timeshow_msg, outnickme(host, nick, nickhtml, "nickme", css, 1) + nbsp() + "<a onclick=\"top.userMenuShow('" + nick + "','" + host + "','" + time_wins + "',this, event,0); return false;\" style=\"cursor: pointer; cursor: hand;\" target=\"_blank\"><img border=0 src=\"http://help.mail.ru/js/user_arrow_pas.gif\" width=\"13\" height=\"13\" alt=\"Меню пользователя\" title=\"Меню пользователя\" align=\"absbottom\"></a>" + nbsp() + "<span id=" + time_wins + " class=msg " + textcss(css) + " onMouseOver=\"top.mnick='" + nick + "'; top.timeids='" + time_wins + "'; top.select=3; return true;\" onMouseClick=\"top.select=3; top.mnick='" + nick + "'; top.timeids='" + time_wins + "'; return true;\" onMouseOut=\"top.select=2;\">" + p1 + "</span>");
- if (p2 != "<away>") updateidle(nick, time);
- break;
- case "q_allmsgbig":
- mcol = "AAAAAA";
- if (top.cook_swf == 1) p1 = p1.replace("embed ", "xembed ");
- if (nick == top.mynick)
- {
- css = replace_mymsg(css);
- mcol = "00B800"
- }
- else if (foundnick)
- {
- css = replace_msgforme(css);
- mcol = "FF3300"
- }
- _out(mcol, css, time, top.timeshow_msg, outnick(host, nick, nickhtml, "nick", css, 1) + nbsp() + "<font class=msgbig " + textcss(css) + "><font class=msgbig>" + p1 + "</font></font>");
- updateidle(nick, time);
- break;
- case "q_join":
- if (top.cook_swf == 1) p1 = p1.replace("embed ", "xembed ");
- if (lite_version == 1) p1 = joinfraz(nick, p1);
- if (p2 != "sdj239eyklfneruiwfuierih340rfmhomdfekejrh3rh34rf34ioru08y39riuerhuh489ry934ruo45tfhuibwf")
- {
- p1 = p1.replace(/{@nick}/, outnick(host, nick, "", "join_nick", css, 0));
- _out('FFC800', css, time, top.timeshow_join, "<font class=join><font face=Webdings>8</font> " + p1 + (host != "" ? " [<a href='http://netchat.ru/chat/whois.php?type=ripe&host=" + host + "' target=_blank><b> info </b></a>] - [" + host + "]" : "") + "</font>")
- }
- if (startevent && nick != mynick) js_e_join(time, 'join', nick, '');
- break;
- case "q_part":
- if (top.cook_swf == 1) p1 = p1.replace("embed ", "xembed ");
- if (lite_version == 1) p1 = partfraz(nick, p1);
- p1 = p1.replace(/{@nick}/, outnick(host, nick, "", "part_nick", css, 0));
- p7 = '';
- if (p2.indexOf('connection') > -1 || p2.indexOf('timeout') > -1) p2 = 'Связь была потеряна...';
- _out('FFC800', css, time, top.timeshow_join, p7 + " <font class=part><font face=Webdings>7</font>" + p1 + (p2 != "" ? " (" + p2 + ")" : "") + (host != "" ? " [<a href='http://netchat.ru/chat/whois.php?type=ripe&host=" + host + "' target=_blank><b> info </b></a>] - [" + host + "]" : "") + "</font>");
- break;
- case "q_notice":
- _out('3399CC', css, time, top.timeshow_notice, "<font class=notice><font face=fixedsys>*</font> " + p1 + "</font>");
- if (startevent) js_e_ntc(time, 'ntc', '', p1);
- break;
- case "q_modes":
- _out('3399CC', css, time, top.timeshow_notice, "<font class=modes>" + p1 + "</font>");
- if (startevent) js_e_ntc(time, 'ntc', '', p1);
- break;
- default:
- parent.frames.irc.document.write("<font color=red size=-1><b>Ошибка287: Неизвестный тип сообщения: " + func + "</b></font><br>")
- }
- if (startevent)
- {
- if ((func == 'q_allmsg' || func == 'q_allmsgme' || func == 'q_allmsgbig') && foundnick)
- {
- if (evbuf1.indexOf("<" + nick + ">") == -1)
- {
- js_e_m1(time, 'm1', nick, p1);
- evbuf1 = "<" + nick + ">" + evbuf1.substr(0, 4000)
- }
- else js_e_m2(time, 'm2', nick, p1)
- }
- if (func == 'q_privget')
- {
- if (evbuf2.indexOf("<" + nick + ">") == -1)
- {
- js_e_pm1(time, 'pm1', nick, p2);
- evbuf2 = "<" + nick + ">" + evbuf2.substr(0, 4000)
- }
- else js_e_pm2(time, 'pm2', nick, p2)
- }
- }
- top.rirclist = 0
- }
- var evbuf1 = "";
- var evbuf2 = "";
- function nbsp()
- {
- return "<font class=nbsp> </font>"
- }
- function textcss(css)
- {
- return " style='" + "font: " + css[7] + " " + css[5] + ";" + "font-weight: " + css[6] + ";" + "color: " + css[8] + ";" + "background: " + css[9] + ";" + "' "
- }
- function nickcss(css)
- {
- return " style='" + "font: " + css[2] + " " + css[0] + ";" + "font-weight: " + css[1] + ";" + "color: " + css[3] + ";" + "background: " + css[4] + ";" + "' "
- }
- function replace_mymsg(css)
- {
- if (!top.mymsg_blink) return css;
- css[5] = (top.mymsg_f == "" ? css[5] : top.mymsg_f);
- css[6] = (top.mymsg_w == "" ? css[6] : top.mymsg_w);
- css[7] = (top.mymsg_f == "" ? css[7] : top.mymsg_f);
- css[8] = (top.mymsg_ct == "" ? css[8] : top.mymsg_ct);
- css[9] = (top.mymsg_cf == "" ? css[9] : top.mymsg_cf);
- return css
- }
- function replace_msgforme(css)
- {
- if (!top.msgforme_blink) return css;
- css[5] = (top.msgforme_f == "" ? css[5] : top.msgforme_f);
- css[6] = (top.msgforme_w == "" ? css[6] : top.msgforme_w);
- css[7] = (top.msgforme_f == "" ? css[7] : top.msgforme_f);
- css[8] = (top.msgforme_ct == "" ? css[8] : top.msgforme_ct);
- css[9] = (top.msgforme_cf == "" ? css[9] : top.msgforme_cf);
- if (top.msgforme_frep) css[4] = css[9];
- return css
- }
- var tmr_sevent = 0;
- function _out(m_col, css, time, show, html)
- {
- top.ignore_sevent = 1;
- if (top.tmr_sevent) clearTimeout(top.tmr_sevent);
- top.tmr_sevent = setTimeout("top.ignore_sevent=0; ", 500);
- parent.frames.irc.document.write("<table width='100%' border=0 style='margin-top:1px;margin-bottom:1px;' cellspacing=0 cellpadding=0 " + (css[9] ? "bgcolor=" + css[9] : "") + "><tr><td bgcolor='#" + m_col + "'><img src='/i/blank.gif' width=3 height=1 alt=''></td><td><img src='/i/blank.gif' width=3 height=1 alt=''></td><td width='100%'>" + (show ? top.mydate(time) : "") + html + "</td></tr></table>")
- }
- function outnick(host, nick, nickhtml, fclass, css, needcss)
- {
- if (nickhtml == '')
- {
- nick1 = top.nickprint_1;
- nick2 = nick;
- nick3 = top.nickprint_2
- }
- else
- {
- var tmp = nickhtml.split("`");
- nick1 = tmp[0];
- nick2 = tmp[1];
- nick3 = tmp[2]
- }
- return xoutnick(host, nick, nick1, nick2, nick3, fclass, css, needcss)
- }
- function outnickme(host, nick, nickhtml, fclass, css, needcss)
- {
- nick1 = top.nickprint_me1;
- nick3 = top.nickprint_me2;
- if (nickhtml == '') nick2 = nick;
- else
- {
- var tmp = nickhtml.split("`");
- nick2 = tmp[1]
- }
- return xoutnick(host, nick, nick1, nick2, nick3, fclass, css, needcss)
- }
- function xoutnick(host, nick, nick1, nick2, nick3, fclass, css, needcss)
- {
- if (fclass == 'join_nick' || fclass == 'part_nick') nick3 = '';
- if (lite_version == 1)
- {
- nick2 = gradnick(nick2)
- }
- return "<a style=\"cursor: pointer; cursor: hand;\" onClick=\"javascript:top.nickcopy('" + nick + "')\" " + "onMouseOver=\"window.status=top.st('" + nick + "'); top.mnick='" + nick + "'; top.mhost='" + host + "'; top.select=1; return true\" " + "onMouseClick=\"window.status='" + top.copy + "'; top.select=1; return true\" " + "onMouseOut=\"window.status='" + top.copy + "'; top.select=2;\" target=kbdpost>" + "<font class=" + fclass + " " + (needcss ? nickcss(css) : "") + "onMouseOver=\"this.style.color='" + top.activenick_ct + "'; this.style.backgroundColor='" + top.activenick_cf + "'; \" " + "onMouseOut=\"this.style.color='" + (needcss ? css[3] : "") + "'; this.style.backgroundColor='" + (needcss ? css[4] : "") + "'; \">" + nick1 + nick2 + nick3 + "</font></a>"
- }
- function userlist_init(x)
- {
- var num;
- top.user = new Array();
- top.userinfo = new Array();
- for (var i = 0; i < x.length; i++)
- {
- top._j(2, '', x[i][0], x[i][1], x[i][2], x[i][3], x[i][4], x[i][5], x[i][6], x[i][7], x[i][8], x[i][9], x[i][10], x[i][11], x[i][12], x[i][13], x[i][14])
- }
- for (i = 0; i < pre_ignore.length; i++)
- {
- num = nick2num(top.pre_ignore[i]);
- if (num >= 0) top.userinfo[num][4] = 1
- }
- }
- function _j(type, skinmsg, p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14)
- {
- if (type == 0 || type == 1) top._in("q_join", p14, p3, p0, p12, p13, skinmsg);
- if (type == 1 || type == 2)
- {
- num = top.user2num(p0);
- if (num == -1) num = top.user.length;
- top.user[num] = [p0, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14];
- top.userinfo[num] = [top.str2chr(p0, 3), type == 1 ? 0 : 1, "", "", 0];
- top.userlist_sort();
- top.userlist_show()
- }
- }
- function _p(type, skinmsg, nick, time, partmsg)
- {
- num = top.user2num(nick);
- if (type == 0 || type == 1) if (num == -1) top._in("q_part", time, "", nick, "", "", skinmsg, partmsg);
- else
- {
- v = top.user[num];
- top._in("q_part", time, v[3], nick, v[12], v[13], skinmsg, partmsg)
- }
- if (type == 1 || type == 2)
- {
- if (num == -1) return;
- top.user = unset(top.user, num);
- top.userinfo = unset(top.userinfo, num)
- }
- top.userlist_show()
- }
- function _u(time, arr)
- {
- var nick, num, digit, i;
- top.rirclist = 0;
- for (i = 0; i < arr.length; i++)
- {
- nick = arr[i][0];
- num = top.user2num(nick);
- if (num == -1)
- {
- parent.frames.irc.location.href = parent.frames.irc.location.href;
- return
- }
- digit = arr[i][1];
- if ((digit & 1) > 0) top.userinfo[num][1] = arr[i][1 + 1];
- if ((digit & 2) > 0)
- {
- top.user[num][8] = arr[i][1 + 2];
- updateidle(nick, time)
- }
- if ((digit & 4) > 0) top.user[num][10] = arr[i][1 + 3];
- if ((digit & 8) > 0)
- {
- top.user[num][1] = arr[i][1 + 4];
- top.s3 = arr[i][1 + 4]
- }
- if ((digit & 16) > 0) top.userinfo[num][2] = arr[i][1 + 5]
- }
- top.userlist_show()
- }
- function updateidle(nick, time)
- {
- var num = top.user2num(nick);
- if (num == -1) return;
- if (!time) time = unixtime();
- top.user[num][10] = "";
- top.user[num][11] = time;
- top.userinfo[num][3] = "";
- top.userlist_show()
- }
- function _set_ignore(nicks)
- {
- var num, i;
- nicks = nicks.split(":");
- for (i = 0; i < top.userinfo.length; i++)
- {
- top.userinfo[i][4] = 0
- }
- for (i = 0; i < nicks.length; i++)
- {
- num = top.user2num(nicks[i]);
- if (num >= 0) top.userinfo[num][4] = 1
- }
- top.userlist_show()
- }
- function _add_ignore(nick)
- {
- var num;
- num = top.user2num(nick);
- if (num >= 0) top.userinfo[num][4] = 1;
- top.userlist_show()
- }
- function _del_ignore(nick)
- {
- var num;
- if (nick == "*")
- {
- for (i = 0; i < top.userinfo.length; i++) top.userinfo[i][4] = 0
- }
- else
- {
- num = top.user2num(nick);
- if (num >= 0) top.userinfo[num][4] = 0
- }
- top.userlist_show()
- }
- function hide_demos()
- {
- document.getElementById("demos").style.display = "none"
- }
- function add_photo(place)
- {
- var div = gebi("chat_info_div");
- div.src = "http://netchat.ru/ajax/loading.html";
- div.src = "http://netchat.ru/chat/add_photo.php";
- div.style.top = absPosition(place).y - 150;
- div.style.left = absPosition(place).x - 335;
- div.style.display = "block"
- }
- function check_orfo(place)
- {
- var div = gebi("chat_info_div");
- div.src = "http://netchat.ru/ajax/loading.html";
- var orfo_text = parent.kbd.document.kbd_form.msgname.value;
- div.src = "http://netchat.ru/ajax/orfo.php?t=" + escape(orfo_text);
- div.style.top = absPosition(place).y - 150;
- div.style.left = absPosition(place).x - 335;
- div.style.display = "block"
- }
- function hidechatalert()
- {
- gebi("alert_chat_div").style.display = "none";
- return false
- }
- function chatalert(text)
- {
- var div = gebi("alert_chat_div");
- gebi("chat_alert_text").innerHTML = text;
- div.style.top = pageHeight() / 2 - 80;
- div.style.left = pageWidth() / 2 - 110;
- div.style.display = "block"
- }
- function hide_check_orfo()
- {
- gebi("chat_info_div").style.display = "none";
- gebi("chat_info_div").src = "http://netchat.ru/ajax/loading.html";
- return false
- }
- function chatModer(_link, id)
- {
- top.topChatModer(id, absPosition(_link).x, absPosition(_link).y, document.body.scrollTop);
- return false
- }
- function topChatModer(id, x, y, frameScroll)
- {
- var iframe, userList, top, left;
- gebi("for_user_info").src = "http://netchat.ru/ajax/loading.html";
- hideModerChat();
- iframe = gebi("for_user_info");
- userList = gebi("list");
- iframe.src = "http://netchat.ru/ajax/uinfo.php?login=" + escape(id);
- iframe.style.display = "block";
- top = absPosition(userList).y + 22;
- iframe.style.top = top > 0 ? top : 0;
- left = absPosition(userList).x + x - iframe.offsetWidth + 20;
- iframe.style.left = left > 0 ? left : 0
- }
- function hideModerChat()
- {
- gebi("for_user_info").style.display = "none";
- gebi("for_user_info").src = "http://netchat.ru/ajax/loading.html";
- return false
- }
- function ChangeSearchAction(type)
- {
- if (type == 2)
- {
- document.getElementById("frame_a_more").style.display = "";
- document.getElementById("frame_c_more").style.display = "none";
- document.getElementById("frame_b_more").style.display = "none";
- document.getElementById("frame_me_more").style.display = "none";
- document.getElementById("stype_1").style.display = "none";
- document.getElementById("stype_2").style.display = ""
- }
- else
- {
- document.getElementById("frame_c_more").style.display = "";
- document.getElementById("frame_a_more").style.display = "none";
- document.getElementById("frame_b_more").style.display = "none";
- document.getElementById("frame_me_more").style.display = "none";
- document.getElementById("stype_1").style.display = "";
- document.getElementById("stype_2").style.display = "none"
- }
- }
- function ChangeSx()
- {
- document.getElementById("frame_b_more").style.display = "";
- document.getElementById("frame_c_more").style.display = "none";
- document.getElementById("frame_a_more").style.display = "none";
- document.getElementById("frame_me_more").style.display = "none"
- }
- function ChangeSxx()
- {
- document.getElementById("frame_me_more").style.display = "";
- document.getElementById("frame_b_more").style.display = "none";
- document.getElementById("frame_c_more").style.display = "none";
- document.getElementById("frame_a_more").style.display = "none"
- }
- function gotrn()
- {
- var trn = document.more_form.trn.checked ? 1 : 0;
- var url = 'http://' + top.http_host + '/' + top.wwp + 'setup.php?c=translit&trn=' + trn + top.asess;
- parent.frames.kbdpost.location = url
- }
- function more_swf()
- {
- if (top.cook_swf == 1)
- {
- top.cook_swf = 0;
- if (top.cook_swf == 0) top.chatalert("Вы услышите все звуковые команды чата! Звуковые уведомления чата настраиваются отдельно на вашей странице настроек.")
- }
- else
- {
- top.cook_swf = 1;
- if (top.cook_swf == 1) top.chatalert("Вы более не будете слышать звуковых команд чата! Звуковые уведомления чата настраиваются отдельно на вашей странице настроек.")
- }
- top.putCookie("swf_disable", top.cook_swf)
- }
- function kbdtime()
- {
- top.mytimes = top.mytimes + 1;
- if (top.mytimes == 60)
- {
- top.mytimes = 0;
- top.mytimem = top.mytimem + 1;
- if (top.mytimem == 60)
- {
- top.mytimem = 0;
- top.mytimeh = top.mytimeh + 1
- }
- }
- gebi("chatdate").innerHTML = top.zero2(top.mytimeh) + ":" + top.zero2(top.mytimem) + ":" + top.zero2(top.mytimes);
- setTimeout("kbdtime()", 1000)
- }
- var clock_i = 0;
- function clock_form()
- {
- clock_time = (timethisx + clock_i) * 1000;
- clock_i = clock_i + 1;
- d = new Date(clock_time + new Date().getTimezoneOffset() - (parent.timezone * 1000));
- m_hh = (d.getHours() < 10 ? "0" + d.getHours() : d.getHours());
- m_mm = (d.getMinutes() < 10 ? "0" + d.getMinutes() : d.getMinutes());
- m_ss = (d.getSeconds() < 10 ? "0" + d.getSeconds() : d.getSeconds());
- m_dd = (d.getDate() < 10 ? "0" + d.getDate() : d.getDate());
- m_mo = ((d.getMonth() + 1) < 10 ? "0" + (d.getMonth() + 1) : (d.getMonth() + 1));
- m_yy = d.getYear();
- str = m_dd + "/" + m_mo + "/" + m_yy + " " + m_hh + ":" + m_mm + ":" + m_ss;
- gebi("htmlDate").innerHTML = str;
- setTimeout("clock_form()", 1000)
- }
- function close_right()
- {
- gebi("right_block").style.display = "none";
- gebi("right_menu").innerHTML = '<img onclick="tc();open_right();return false;" onMouseOver="ts(this, event, 2);" onMouseOut="tc()" style="cursor: pointer; cursor: hand;" src="/i/right_open.gif" width=15 border=0 alt="" height=74 vspace=9><br>';
- set_focus()
- }
- function open_right()
- {
- gebi("right_block").style.display = "";
- gebi("right_menu").innerHTML = '<img onclick="tc();close_right();return false;" onMouseOver="ts(this, event, 1)" onMouseOut="tc()" style="cursor: pointer; cursor: hand;" src="/i/right_close.gif" width=15 border=0 alt="" height=51 vspace=9><br>';
- set_focus()
- }
- function close_down()
- {
- gebi("down_block").style.display = "none";
- gebi("down_menu").innerHTML = '<img onclick="open_down();return false;" style="cursor: pointer; cursor: hand;" src="/i/down_open.gif" width=74 border=0 alt="" height=15 vspace=1><br>';
- set_focus()
- }
- function open_down()
- {
- gebi("down_block").style.display = "";
- gebi("down_menu").innerHTML = '<img onclick="tc();close_down();return false;" onMouseOver="ts(this, event, 1)" onMouseOut="tc()" style="cursor: pointer; cursor: hand;" src="/i/down_close.gif" width=51 border=0 alt="" height=15 vspace=1><br>';
- set_focus()
- }
- var frm_more_load = 0;
- var frm_list_load = 0;
- var frm_kbd_load = 0;
- var frm_firc_load = 0;
- var frm_kbdnull_load = 0;
- var frm_snd_load = 0;
- function check_load()
- {
- var loaded = 0;
- if (top.frm_more_load == 0)
- {
- loaded = loaded + 1;
- gebi("more").src = 'http://netchat.ru/chat/frame_more.php?&PHPSESSID=f6aeb848d082140f500bbae2e396c8e2&'
- }
- if (top.frm_list_load == 0)
- {
- loaded = loaded + 1;
- gebi("list").src = 'http://netchat.ru/chat/frame_list.php?&PHPSESSID=f6aeb848d082140f500bbae2e396c8e2&'
- }
- if (top.frm_kbd_load == 0)
- {
- loaded = loaded + 1;
- gebi("kbd").src = 'http://netchat.ru/chat/frame_kbd.php?&PHPSESSID=f6aeb848d082140f500bbae2e396c8e2&'
- }
- if (top.frm_firc_load == 0)
- {
- loaded = loaded + 1;
- gebi("irc").src = 'http://netchat.ru/chat/firc.php?&PHPSESSID=f6aeb848d082140f500bbae2e396c8e2&'
- }
- if (top.frm_kbdnull_load == 0)
- {
- loaded = loaded + 1;
- gebi("kbdnull").src = 'http://netchat.ru/chat/frame_kbdnull.php?&PHPSESSID=f6aeb848d082140f500bbae2e396c8e2&'
- }
- if (loaded > 0)
- {
- setTimeout("check_load()", 5000)
- }
- }
- function put_smiles(smile)
- {
- var p = parent.frames.kbd.document.kbd_form;
- p.msgname.value = p.msgname.value + ' :' + smile + ': ';
- p.msgname.focus()
- }
- function openfoto(a)
- {
- window.open('http://netchat.ru/ajax/show_photo.php?id=' + a, '_blank', 'width=120,height=120,toolbar=no,location=no,directories=no,menubar=no,scrollbars=no,resizable=yes,status=no')
- }
Advertisement
Add Comment
Please, Sign In to add comment