function PopupPic(sPicURL) 
{
    if(sPicURL.length>0)
    {
        var w = 600;
        var h = 600;
        var winl = (screen.width - w) / 2;
        var wint = (screen.height - h) / 2;
        var winprops ='height=600 ,width=600,top='+300+',left='+100+'resizable=true'       
        window.open("/popups/vizualizareFotografie.html?"+sPicURL, "", winprops);     
    }                     
}

function menuHover(elem)
{
	elem.className="menuItemHover"
}
function resetMenuHover(elem)
{
	elem.className="menuItem"
}

function focusOn(elem)
{
	elem.style.backgroundColor = '#E3EFD0';
	elem.style.border='1px #69AA00 solid';
}

function focusOff(elem)
{
	elem.style.backgroundColor = '#CCCCCC';
	elem.style.border='1px #ffffff solid';
}

function setFocus(elem)
{
	document.getElementById(elem).focus();
}

function focusOnOrder(elem)
{
	elem.style.backgroundColor = '#ffffff';
	elem.style.border='1px #197519 solid';
}

function focusOffOrder(elem)
{
	elem.style.backgroundColor = '#ffffff';
	elem.style.border='1px #69AA00 solid';
}



function FCKValue(id)
{
    var temp = document.createElement('txBuffer');
    temp.value = FCKeditorAPI.GetInstance(id).GetXHTML();
    return temp;
}

function $$() {
        
	if (arguments.length>1) {
		return false;
	}
	if (arguments.length<1) {
		return false;
	}

	var element = arguments[0];

    if (typeof element == 'string') {
        if (document.getElementById) 
        {
            try 
            {
                element = FCKValue(element);
            }
            catch(err)
            {
                element = document.getElementById(element);            
            }

        } else if (document.all) {
            element = document.all[element];
        }
    }
    
	
	return element;
}