﻿// top.js (c) 1453 Fatih Sultan Mehmet
// mozilla text selection code by lhurgoyf & serendipity 
// opera text selection workaround by baka
// safari text selection workaround by passion

var yok = "ekşi sözlük - kutsal bilgi kaynağı";
var bid = 0, lo = null, hreq = false, is = "", se = "", pr = '<td><a onmousedown="md(this)" onmouseup="bn(this)" onmouseover="ov(this)" onmouseout="bn(this)" class="but" ', sprite = 0, dcss = "sozluk.css";
var tms = new Array();

function G(i) {
    return document.getElementById(i);
}

function togdisp(o) {
    o.style.display = (o.style.display == 'none') ? 'block' : 'none';
}

function togvis(o) {
    o.style.visibility = (o.style.visibility == 'hidden') ? 'visible' : 'hidden';
}

function ov(o) {
    o.id = "butOver";
}

function md(o) {
    o.id = "butDown";
}

function bn(o) {
    o.id = "";
}

function b(t, u, c, tt) {
    document.write(pr);
    if (tt) document.write(" title='" + tt + "'");
    document.write(' target=' + t + ' href="' + u + '">&nbsp;' + c + '&nbsp;</a></td>');
}

function b2(t, u, c, s) {
    document.write(pr.replace("<td>", "<td colspan=" + s + ">") + 'target="' + t + ' href="' + u + '">&nbsp;' + c + '&nbsp;</a></td>');
}

function s(f, c) {
    document.write(pr + 'onclick="G(\'' + f + '\').submit()" style="cursor:hand">&nbsp;&nbsp;' + c + '&nbsp;</a></td>');
}

function a(u, c, t) {
    document.write(pr + 'title="' + t + '" href="' + u + '" class="icon">&nbsp;' + c + '&nbsp;</a></td>');
}

function p(u, c, t, m) {
    document.write(pr + 'title="' + t + '" onclick="return confirm(\'' + m + '\')" href="' + u + '" class="icon">&nbsp;' + c + '&nbsp;</a></td>');
}

function al() {
    for (var c = 'a'; c <= 'z'; c++) document.write('<a target="index" href="index.asp?ix=' + c + '">' + c + '</a> ');
}

function get() {
    var o = G('fg');
    o.submit();
}

function ara() {
    if (top.sozindex) top.sozindex.location.href = 'index.asp?a=sr&kw=' + G('t').value;
}

function mch() {
    var u = "t=";
    var c = document.getElementsByTagName("input")
    for (i = 0; i < c.length; i++)
        if (c[i].type == "checkbox" && c[i].name == "mxx" && c[i].checked)
        u += "&m=" + c[i].value;
    od('movemulti.asp?' + u);
}
function ct() {
    tc = G('ctf');
    if (tc) {
        var i = document.getElementsByTagName("input")
        var c = 0;
        for (j = 0; j < i.length; j++) { if (i[j].type == "checkbox") { if (i[j].checked) c++; } }
        tc.style.display = c > 0 ? 'inline' : 'none';
    }
}

function ci(i) {
    ic = G('c' + i);
    with (ic) {
        style.display = style.display == 'none' ? 'inline' : 'none';
        checked = checked ? false : true;
        ct();
    }
}
function oi(n) {
    od('info.asp?n=' + encodeURIComponent(n), 400, 420);
}
function e(f, i, an, re) {
    with (document) {
        write('<br /><table id="m' + i + '" style="visibility:hidden;float:right"><tr>');
        write('<td class="ei" id="vst' + i + '" style="white-space:nowrap">&nbsp;</td>');
        write('<td class="ei"><a href="javascript:void(0)" onclick="copyid(' + i + ',' + f + ');">#' + i + '</a></td>');
        if (f & 16) {
            a("javascript:mpr(" + i + ",1)", ":)", "şükela!");
            a("javascript:mpr(" + i + ",0)", ":O", "öeehh");
            a("javascript:mpr(" + i + ",-1)", ":(", "çok kötü");
            document.write('<td>&nbsp;</td>');
            a("javascript:od('msg.asp?to=" + ean(an) + "&re=" + i + "')", "/msg", "mesaj at");
            a("javascript:oi('" + ean(an) + "')", "?", "yazar hakkında");
        }
        a("javascript:var w=window.open('share.asp?to=fb&u='+encodeURIComponent('http://sozluk.sourtimes.org/show.asp?fb=1&id=" + i + "')+'&t='+encodeURIComponent(document.title))", "fb", "feysbuk'ta paylaş");
        if (f & 2) a("javascript:od('gammaz.asp?id=" + i + "',430,160)", ":P", "ispiyonla");
        if (f & 128) a("javascript:od('addfave.asp?id=" + i + "')", "-D", "favorilere ekle");
        if (f & 1) a("javascript:ci(" + i + ")", "&gt;", "taşı");
        if (f & 4) a("edit.asp?id=" + i + "&ref=" + (re ? re : ""), "...", "düzelt");
        if (f & 32) a("show.asp?a=eh&id=" + i, "~", "düzeltme tarihçesi");
        if (f & 64) a("showmodhistory.asp?id=" + i, "!", "moderasyon tarihçesi");
        if (f & 8) a("javascript:od('del.asp?id=" + i + "',430,160)", "X", "sil");
        if (f & 256) { document.write('<td>&nbsp;</td>'); a("javascript:location.href='iletisim.asp?s=1&id=" + i + "'", "şikayet et", "aynen öyle"); }
        if (f & 512) a("javascript:od('del.asp?p=y&id=" + i + "')", "X", "tamamen sil");
        write('</tr></table><br /><br />');
        var d = getElementById('d' + i);
        var m = "G('m" + i + "').style.visibility=";
        d.onmouseover = new Function(m + "'visible'");
        d.onmouseout = new Function(m + "'hidden'");
    }
}

function setmsg(fi, ft, an) {
    fi.value = an;
    ft.focus();
}

function ean(an) {
    return encodeURIComponent(an.replace(/\'/g, "\\\'"));
}

function due(s) {
    return decodeURIComponent(s).replace(/\+/g, " ");
}

function trm(s) { return s.replace(/^\s+|\s+$/g, ''); }
function nada(s) { return trm(s).length == 0; }

function me(f, i, an) {
    with (document) {
        write('<span style="text-align:right"><table id="m' + i + '" style="visibility:hidden"><tr><td style="width:100%">&nbsp;</td>');
        if (f & 4) {
            a("javascript:setmsg(G('to'),G('msg'),'" + ean(an) + "')", "cevab ver", "popup beklemeden mesaj yazma aparatı");
            a("javascript:od('msg.asp?to=" + ean(an) + "')", "/msg", "mesaj at");
            a("javascript:oi('" + ean(an) + "')", "?", "yazar hakkında");
        }
        if (f & 2) a("javascript:od('domsg.asp?a=a&amp;id=" + i + "')", "->", "arşivle");
        if (f & 1) a("javascript:dd(" + i + ")", "X", "sil");

        write('</tr></table></span>');
        var d = getElementById('d' + i);
        var m = "G('m" + i + "').style.visibility=";
        d.onmouseover = new Function(m + "'visible'");
        d.onmouseout = new Function(m + "'hidden'");
    }
}

function copyid(id, f) {
    var c = G('cidtxt');
    var u = "http://sozluk.sourtimes.org/show.asp?id=" + id;
    var s = '#' + id;
    var p = s + ' numaralı entry\'nin adresi';
    if (!c) { prompt(p, u); return; }
    if (document.selection) {
        c.innerText = u;
        var ct = c.createTextRange();
        ct.execCommand("Copy");
    } else {
        prompt(p, u)
    }
}

function dd(i) {
    od('domsg.asp?a=d&id=' + i);
    G('d' + i).style.visibility = 'hidden';
}

function tr(i) {
    document.write('<tr style="cursor:default" onmouseover="G("m' + i + '").style.visibility=\'visible\'" onmouseout="style.borderWidth=\'0\';G("m' + i + '").style.visibility=\'hidden\'">');
}

function od(u, w, h) {
    if (!w) w = 320; 
    if (!h) h = 200; 
    var w = window.open(u, "_blank", "resizable=yes,scrollbars=yes,width=" + w.toString() + ",height=" + h.toString());
    w.focus();
}

function odf(u, w, h) {
    od(u, w, h); 
    return false;
}

function au(d) {
    document.write('<tr><td nowrap align="right" class="aul">(<a class="aul" href="?t=' + an + '">' + an + '</a>, ' + d + ')</td></tr>');
}

function sets(doc, fn) {
    if (doc) {
        var len = doc.styleSheets.length;
        if (doc.createStyleSheet) {
            if (fn.length == 0) {
                if (len > 1) doc.styleSheets[1].href = "";
            } else {
                if (len < 2) doc.createStyleSheet(fn); else doc.styleSheets[1].href = fn;
            }
        } else {
            doc.location.reload();
        }
    }
}

function b2r() {
    if (!document.createStyleSheet) {
        return false;
    }
    if (top.sozbar) sets(top.sozbar.document, dcss);
    if (top.sozindex) sets(top.sozindex.document, dcss);
    if (top.sozmain) sets(top.sozmain.document, dcss);
    return true;
}

function bp(o, m, c) {
    var oo;
    for (var n = 1; n <= m; n++) {
        oo = document.createElement("OPTION");
        o.options.add(oo);
        oo.innerText = n;
        oo.Value = n;
        oo.selected = n == c;
    }
}

var inpp = false, n, o = null, maxs = 5, mx = 20, lx = 30, w, bi = 1, sint = null;

function osr() {
    o = null;
    os();
}

function os() {
    if (o == null) {
        o = G('a');
        window.onscroll = os;
        window.onresize = osr;
        w = document.documentElement.clientWidth;
        sint = new Array();
        for (n = 0; n <= maxs; n++) sint[n] = (parseInt(Math.sin((Math.PI * n / 2) / maxs) * (w - mx - lx)) + lx) + "px";
        o.style.left = sint[n = maxs]; o.style.width = (w - parseInt(sint[n]) - 2) + "px";
        if (sprite == 1) {
            var o_s = G('a' + 's');
            o_s.style.left = sint[n = maxs]; o_s.style.width = (w - parseInt(sint[n]) - 2) + "px";
        }
    }
    if (o.clientHeight + 44 < document.documentElement.clientHeight)
        o.style.top = (document.documentElement.scrollTop + 44) + "px";
    if (sprite == 1) {
        var o_s = G('a' + 's');
        if (o_s.clientHeight + 208 < document.documentElement.clientHeight)
            o_s.style.top = (document.documentElement.scrollTop + 208) + "px";
    }
}

function ca() {
    var amain = G('amain');
    n += bi; o.style.left = sint[n]; o.style.width = (w - parseInt(sint[n]) - 2) + "px";
    if (bi == 1) if (n < maxs) setTimeout("ca()", 20); else { document.body.focus(); amain.disabled = true; o.style.zIndex = 0; inpp = false; }
    else if (n > 0) setTimeout("ca()", 20); else { amain.disabled = false; var kw = G('kw'); if (kw) kw.focus(); inpp = false; }
}

function pp() {
    if (!o) return;
    if (!inpp) {
        inpp = true;
        if (sprite == 1) if (bi > 0 && bi_s < 0) { pp_s('s'); inpp = false; return; }
        if (bi > 0) o.style.zIndex = 1;
        bi = -bi; ca();
        inpp = false;
        return;
    }
}

function ods(n, s, f) {
    document.write(' <select name="' + n + '"><option></option>');
    for (var n = 1; n <= 31; n++) document.write("<option " + (n == f ? "selected='selected'" : "") + ">" + n + "</option>");
    if (s) for (n = 2; n <= 12; n++) document.write("<option value=" + (n * 30) + ">" + n + " ay</option>");
    document.write('</select>');
}

function oms(n, f) {
    var mo = new Array("ocak", "şubat", "mart", "nisan", "mayıs", "haziran", "temmuz", "ağustos", "eylül", "ekim", "kasım", "aralık");
    document.write(' <select name="' + n + '"><option></option>');
    for (var n = 1; n <= 12; n++) document.write("<option " + (n == f ? "selected='selected'" : "") + " value='" + n + "'>" + mo[n - 1] + "</option>");
    document.write('</select>');
}

function oys(n, f) {
    document.write(' <select name="' + n + '"><option></option>');
    with (new Date()) for (var n = getFullYear(); n >= 1999; n--) document.write("<option " + (n == f ? "selected='selected'" : "") + ">" + n + "</option>");
    document.write('</select>');
}

function ors(t) {
    document.write(
    '<option>..araştır..</option>' +
    '<option value="http://www.google.com.tr/search?q=">google</option>' +
    '<option value="http://www.tdk.gov.tr/TR/Genel/SozBul.aspx?F6E10F8892433CFFAAF6AA849816B2EF4376734BED947CDE&Kelime=">tdk sözlüğü</option>' +
    '<option value="http://www.tureng.com/search/">tureng sözlük</option>' +
    '<option value="http://www.nisanyansozluk.com/search.asp?w=">etimolojik sözlük</option>' +
    '<option value="http://tr.wikipedia.org/w/index.php?title=%C3%96zel:Ara&fulltext=Ara&search=">vikipedi</option>' +
    '<option value="http://en.wikipedia.org/wiki/Special:Search?fulltext=Search&search=">wikipedia</option>' +
    '<option value="http://www.mobygames.com/search/quick?q=">mobygames</option>' +
    '<option value="http://us.imdb.com/find?q=">imdb</option>' +
    '<option value="http://www.youtube.com/results?search_query=">youtube</option>');
}

function orse() {
    document.write('</select>');
}

function orsc(c, t) {
    document.write('<select class="asl" onchange="if(this.selectedIndex>0){window.open(decodeURIComponent(this.options[this.selectedIndex].value)+\'' + t + '\');this.selectedIndex=0;}">');
    ors(t);
    if (c.length == 0) { orse(); return }
    var j = gcol(c); if (!j) { orse(t); return }
    for (var i = 0; i < j; i++) {
        var li = gco(c + "li" + i);
        var ln = gco(c + "ln" + i);
        if (li) document.write('<option value="' + li + '">' + ln + '</option>');
    }
    orse(t);
}

function gcol(ci) {
    var n = 0;
    var c = document.cookie.split(";")
    for (var i = 0; i < c.length; i++) {
        var e = c[i].split("=");
        if (e[0].indexOf(ci + "li") != -1) n++;
    }
    return n;
}

function gcok(o) {
    var e = document.cookie.indexOf(";", o);
    if (e == -1) { e = document.cookie.length }
    return decodeURIComponent(document.cookie.substring(o, e).split('+').join(' '));
}

function gco(n) {
    var a = n + "=";
    var al = a.length;
    var cl = document.cookie.length;
    var i = 0;
    while (i < cl) {
        var j = i + al;
        if (document.cookie.substring(i, j) == a) {
            return gcok(j);
        }
        i = document.cookie.indexOf(" ", i) + 1;
        if (i == 0) break;
    }
    return null;
}

function trim(s) {
    return s.replace(/^\s\s*/, '').replace(/\s\s*$/, '');
}

function henti(s, a, b) {
    var ts = trim(s);
    var ps = s.indexOf(ts);
    return s.substring(0, ps) + a + ts + b + s.substring(ps + ts.length, s.length);
}

function hen(d, a, b, m) {
    var o = G(d), tmp = o.scrollTop, f = true, rg;
    o.focus();
    if (document.selection) {
        rg = document.selection.createRange();
        if (rg.parentElement() == o) {
            rg.text = henti(rg.text, a, b);
            rg.select();
            f = false;
        }
    } else if (o.selectionEnd) {
        var s = o.value, end = o.selectionEnd, start = o.selectionStart;
        if (s.length > 0) {
            o.value = s.substring(0, start) + henti(s.substring(start, end), a, b) + s.substring(end);
            end += a.length + b.length;
            o.setSelectionRange(end, end);
            f = false;
        }
    }
    if (f) {
        var s = m.length > 0 ? prompt(m, "") : "";
        if (m.length == 0 || s.length > 0) o.value += ' ' + a + trim(s) + b;
    }
    o.scrollTop = tmp;
    return true;
}

function tac() {
    var c = document.getElementsByTagName("input");
    for (var i = 0; i < c.length; i++) if (c[i].type == "checkbox") c[i].checked = !c[i].checked;
}

function selcnt() {
    var c = document.getElementsByTagName("input");
    var cnt = 0;
    for (var i = 0; i < c.length; i++) if (c[i].type == "checkbox") cnt += c[i].checked ? 1 : 0;
    return cnt;
}

function dbln4(e, i) {
    var k, c;
    if (window.event) { k = e.keyCode; c = e.ctrlKey; } else { k = e.which; c = e.ctrlKey; }
    if (c && (k == 10 || k == 13)) G(i).submit();
}
function dbsim(e, b) {
    var k, c;
    if (window.event) k = e.keyCode; else k = e.which;
    if (k == 13) G(b).click();
}
function vmsg(frm) {
    if ((frm.to.value.length | frm.msg.value.length) == 0) {
        alert("boş işler bunlar");
        return false;
    } else if (frm.msg.value.length > 8000) {
        alert("mesajı çok uzun yazmışsınız bizimle merkeze kadar geleceksiniz");
        return false;
    }
    return true;
}
function tdb(i) {
    with (G(i).style) display = (display == "block") ? "none" : "block";
}
function bye() {
    if (confirm('ekşi sözlük\'ten çıkıyorsunuz?')) location.href = 'logoff.asp';
}

function gax() {
    var r = false;
    if (window.XMLHttpRequest) { // mozilla, safari, etc.
        r = new XMLHttpRequest();
        if (r.overrideMimeType) {
            r.overrideMimeType('text/html');
        }
    } else if (window.ActiveXObject) { // ie
        try {
            r = new ActiveXObject("Msxml2.XMLHTTP");
        } catch (e) {
            try {
                r = new ActiveXObject("Microsoft.XMLHTTP");
            } catch (e) { }
        }
    }
    return r;
}

function ctims(id) {
    if (typeof (tms[id]) == 'object') {
        if (tms[id].length) {
            clearTimeout(tms[id][0]);
            clearTimeout(tms[id][1]);
        }
    }
    return new Array();
}

function mwa(v, id, c) {
    // wait for the response a total of 45 seconds or cancel
    if (c == 4) {
        hreq = false;
        clearTimeout(tms[id][0]);
        tms[id][1] = setTimeout(
      function(v) {
          return function() {
              v.innerHTML = '';
          };
      } (v), 8000);
        v.innerHTML = 'olmadı galiba. tekrar deneyin.';
        return;
    }
    tms[id][1] = setTimeout(
    function(v) {
        return function() {
            v.innerHTML = 'biraz daha sürecek #' + (++c);
            mwa(v, id, c);
        };
    } (v), 15000);
}

function mpr(id, w, c) {
    var p = 'id=' + id + '&v=' + w;
    if (hreq) return;
    var h = gax();
    if (!h) { alert('oyunuzu gönderemiyoruz çünkü web tarayıcınız bir şeyleri desteklemiyor.'); return }
    hreq = h;
    var v = G('vst' + id); if (!v) return;
    tms[id] = ctims(id);
    hreq.open('POST', 'votejx.asp', true);
    hreq.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
    hreq.onreadystatechange = function() {
        if (hreq.readyState == 4) {
            if (hreq.status == 200) {
                v.innerHTML = c ? 'tamam geçti korkma.' : 'oyunuz kaydedildi. (<a href="javascript:mpr(' + id + ',-2,1)">geri al</a>)';
            } else {
                v.innerHTML = 'bir sebepten oyunuz gidemedi';
            }
            hreq = false;
            clearTimeout(tms[id][1]);
            tms[id][0] = setTimeout(
        function(v) {
            return function() {
                v.innerHTML = '';
            };
        } (v), 8000);
        }
    }
    mwa(v, id, 1);
    v.innerHTML = 'oluyor';
    hreq.send(p);
}
function fff(w, f) {
    var m = "Dr. Watson: Aman yazdıkların boşa gitmesin!\n\n" + f.value.substr(0, 30) + "...\n";
    if (f.value != f.defaultValue) {
        w.onbeforeunload = function() {
            f.focus();
            if (document.all && event) event.returnValue = m
            else return m
        }
    } else nof(w);
}

function nof(w) { w.onbeforeunload = function() { } }

function vt(ta, len) {
    if (ta.value.length <= len) return true;
    alert("yazdığınız " + len + " karakterden uzun (" + (ta.value.length - len) + " fazlası var)");
    return false;
}

function hrTimeout(hr, d) {
    return function() {
        hr.timedout = true;
        hr.abort();
        d.innerHTML = "timeout";
    }
}
function chkdb() {
    var hr = gax();
    if (!hr) return false;
    hr.open('GET', 'dbconnjx.asp', true);
    hr.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
    hr.send();
    hr.onreadystatechange = function() {
        if (hr.readyState != 4) return;
        clearTimeout(hr.abortTimer);
        if (hr.timedout) return;
        if (hr.status == 200) {
            location.reload(); // db is back!
        } else {
            setTimeout(chkdb, 5 * 30 * 1000);
        }
    }
    hr.send(p);
}
function dsajx(id, code, title) {
    var d = G((code == 'ed' ? 'vt' : 'sl') + id);
    var b
    if(!d) return;
    var hr = gax();
    if (!hr) return false;
    var p = "a=" + code + "&s=" + id
    if (code == 'ed') {
        p = p + "&nr=" + encodeURIComponent(title)
        b = G('gb' + id)
        if (b) b.style.display = 'none';
    }
    d.innerHTML = "işleniyor..."
    hr.open('POST', 'dosucksjx.asp', true);
    hr.setRequestHeader("Content-type", "application/x-www-form-urlencoded");
    hr.onreadystatechange = function() {
        if(hr.readyState != 4) return;
        clearTimeout(hr.abortTimer);
        if(hr.timedout) return;
        if(hr.status == 200) {
            if (code == 'ed') {
                G('rd' + id).innerHTML = hr.responseText;
                if (b) b.style.display = "block";
                d.innerHTML = '';
            } else {
                d.innerHTML = "işlendi<br/>(" + title + ")<br/><br/>";
            }
        } else if (hr.status > 0) {
            d.innerHTML = "beceremedik biz bu işi <br/>(" + hr.statusText + ")<br/>" + hr.responseText;
        }
    }
    hr.abortTimer = setTimeout(hrTimeout(hr, d), 30000);
    hr.timedout = false;
    hr.send(p)
}
function nmosf() {
    var a = navigator.userAgent.toLowerCase();
    var m = (a.indexOf('mobile') != -1);
    var s = (a.indexOf('safari') != -1);
    return (!m || !s || typeof (window.Touch) != "object");
}
function oci() {
    document.write("bu sitede yazılanların hiçbiri doğru değildir. site içeriği küçükler için sakıncalı olabilir. \
yazılardan yazarları sorumludur. kaynak göstermeden alıntılanamaz. devlet tarafından atanmış bir kurumun \
internet üzerinde kimin hangi bilgiye ulaşıp ulaşamayacağına karar vermesi insan haklarına aykırıdır. \
web siteleri kullanıcıların istekleri doğrultusunda bağlandıkları yerlerdir. kullanıcılar isterlerse bir \
web sitesine bağlanmayabilirler. bu güçleri ve imkanları mevcuttur. bir kullanıcı bir siteye bağlanmak \
istiyorsa bu onun tercihi ve hakkıdır. bağlanmak istemiyorsa bu yine onun tercihi ve \
hakkıdır. halkın kendisine hizmet etmesi için görevlendirdiği kurumlar hadlerini aşıp halka neye ulaşıp \
ulaşmayacağını bilmeyen cahil cühela muamelesi edemezler. ebeveynlerin çocuklarını sakıncalı içeriklerden \
koruması için çok sayıda bedava ve ücretli yazılım mevcuttur. bu yazılımlar bir web tarayıcısını kullanmaktan \
daha karmaşık teknik bilgi gerektirmemektedir. devletin milletini küçük düşürmesi ve ebleh yerine \
koyması yasaktır.");
}
function tou() {
    top.document.title = yok;
}
function tol(jt) {
    top.document.title = yok + ' - ' + jt;
    if (gqs("txt").length == 0) return;
    G('d').focus();
}
function gqsw(k, w) {
    var qs = w.location.search.substring(1).split("&");
    for (var n = 0; n < qs.length; n++) {
        var sub = qs[n].split("=");
        if (sub[0] == k && sub.length == 2) return decodeURIComponent(sub[1].split('+').join(' '));
    }
    return "";
}
function gqs(k) {
    return gqsw(k, this);
}

function asup() {
    return external && typeof(external.AddService) == "unknown";
}

function sie8() {
    var o = G('ie8');
    o.style.display = "none";
    if (asup() && !window.external.IsServiceInstalled(location.protocol + '//' + location.host, 'Dictionaries and Reference')) 
        o.style.display = "inline-block";
    o = G('ws');
    o.style.display = "none";
    if (asup() && typeof(window.external.AddToFavorites) != "unknown")
        o.style.display = "inline-block";
}