﻿function OpenWindow(url, name, width, height, enableScrollbars, resizable) {
    var scrollbars = 'no';
    if (enableScrollbars)
    {
        scrollbars = "yes";  
    }
	winhandle=window.open(url, name, "width=" + width + ",height=" + height + ",scrollbars=" + scrollbars + ",resizable=no,status=no,menubar=no");
	winhandle.focus();
}
function CloseWindow()
{
    window.close();
}
function OpenMemberProfile(UID, link) 
{
	OpenWindow(link + "?UID=" + UID,"ConsultantProfile",420,400,false);
}
function OpenCompanyProfile(CID, link) 
{
	OpenWindow(link + "?CID=" + CID,"CompanyProfile",420,400,false);
}
function OpenMessage(MessageID, link) 
{
	OpenWindow(link + "?MID=" + MessageID,"Message",450,400,true);
}

function OpenQuestionDescription()
{
    OpenWindow("../../companies/popups/Question.aspx","Description",450,400,true);
}
function OpenTestDescription()
{
    OpenWindow("../../companies/popups/Test.aspx","Description",450,400,true);
}
function OpenRSDescription()
{
    OpenWindow("../../companies/popups/ResumeSearch.aspx","Description",450,400,true);
}
function OpenAdDescription()
{
    OpenWindow("../../companies/popups/Advertising.aspx","Description",450,400,true);
}
function OpenCCCDescription()
{
    OpenWindow("../../companies/popups/CCC.aspx","Description",450,400,true);
}
function OpenCompanyMessage(link)
{
    window.opener.location = link;
}
function OpenQuestion(QID, link) 
{
	OpenWindow(link + "?QID=" + QID,"Question",450,400,true);
}
function OpenReferralPage(link, type)
{
    OpenWindow(link + "?t=" + type,"Referrals",450,400,true);
}