// Генерация нового окна для картинки
var wpopup = null;
function closewpop(){
//alert ("!!!");
        if (wpopup != null) {
                wpopup.close();
                wpopup = null;
        }
}

function showbigpic(iURL, iW, iH, iTitle){
        if (wpopup == null) {
                wpopup = open("", "wpopup", "width=" + iW + ",height=" + iH);
        }
        else
        {
                wpopup.close();
                wpopup = null;
                wpopup = open("", "wpopup", "width=" + iW + ",height=" + iH);
        }
        wpopup.document.write("<html><head>\n");
        wpopup.document.write('<meta http-equiv="Content-Type" content="text/html; charset=windows-1251">\n');
        wpopup.document.write("</head>\n");
        wpopup.document.write("<body bgcolor='#FFFFFF' leftmargin='0' topmargin='0' marginwidth='0' marginheight='0' onClick='self.close();'>\n");

        wpopup.document.write("<img src='" + iURL + "' border='0'  vspace='0'  name='zzz' hspace='0'  alt='"+iTitle+"'></body></html>");
//        wpopup.document.write (wpopup.document.images['zzz'].complete) ;
        while (wpopup.document.images['zzz'].complete != true) {};
        var deltax = wpopup.document.images['zzz'].width-wpopup.document.body.clientWidth;
        var deltay = wpopup.document.images['zzz'].height-wpopup.document.body.clientHeight;
        wpopup.resizeBy(deltax, deltay);

        wpopup.document.title = (iTitle == null) ? "" : iTitle;
        wpopup.focus();
        wpopup.document.close();
}

// Меню
f=1;
browserVer=parseInt(navigator.appVersion);
if (browserVer>2){
bot1_1 = new Image;
bot1_2 = new Image;
bot1_1.src="images/kn.gif";
bot1_2.src="images/ka.gif";
bot2_1 = new Image;
bot2_2 = new Image;
bot2_1.src="images/un.gif";
bot2_2.src="images/ua.gif";
bot3_1 = new Image;
bot3_2 = new Image;
bot3_1.src="images/an.gif";
bot3_2.src="images/aa.gif";
bot4_1 = new Image;
bot4_2 = new Image;
bot4_1.src="images/gallery.jpg";
bot4_2.src="images/gallery_a.jpg";
bot5_1 = new Image;
bot5_2 = new Image;
bot5_1.src="images/vacancy.jpg";
bot5_2.src="images/vacancy_a.jpg";
bot6_1 = new Image;
bot6_2 = new Image;
bot6_1.src="images/k.gif";
bot6_2.src="images/k2.gif";
}
function selectbot(imgID,imgSelectName)
{
if (browserVer < 3) return;
if (null!=document.images["bot"+eval(imgID)]) document.images["bot"+eval(imgID)].src = eval("bot"+imgID+"_"+imgSelectName+".src");
}

function sel(imgID,img3)
{
this.selectbot=selectbot;
}

// Генерация Майла
function email (login, sc)
{
var serv = new Array;
serv[0] = "expertag.ru";
serv[1] = "yandex.ru";
serv[2] = "alro.ru";
eml = login +  "@" + serv[sc];
return eml;
}

function mylo (login, sc)
{
document.write (email(login, sc));
}

function namylo (login, sc, sub)
{
eml = "mailto:" + email(login, sc);
if (sub != "") eml += "?subject=" + sub;
window.location.href = eml;
}