';
if(OpenWin) OpenWin.close();
if(pwidth > 1024 || pheight > 768)
OpenWin = this.open('', "CtrlWindow", "width=" + width + ",height=" + height + " toolbar=no, menubar=no, location=no, scrollbars=yes, statusbar=no, resizable=yes, screenX="+x+", screenY="+y+", left="+x+", top="+y);
else
OpenWin = this.open('', "CtrlWindow", "width=" + width + ",height=" + height + " toolbar=no, menubar=no, location=no, scrollbars=no, statusbar=no, resizable=yes, screenX="+x+", screenY="+y+", left="+x+", top="+y);
OpenWin.document.write(content);
OpenWin.focus();
}
function currencyPopup(file) {
var x = (screen.width-500)/2;
y = (screen.height-300)/2;
OpenWin = this.open(file, "CtrlWindow", "width=300,height=400 toolbar=no,menubar=no,location=no,scrollbars=yes,resizable=no, screenX="+x+", screenY="+y+", left="+x+", top="+y);
}
/**
* Sets a Cookie with the given name and value.
*
* name Name of the cookie
* value Value of the cookie
* [expires] Expiration date of the cookie (default: end of current session)
* [path] Path where the cookie is valid (default: path of calling document)
* [domain] Domain where the cookie is valid
* (default: domain of calling document)
* [secure] Boolean value indicating if the cookie transmission requires a
* secure transmission
*/
function setCookie(name, value, expires, path, domain, secure)
{
document.cookie= name + "=" + escape(value) +
((expires) ? "; expires=" + expires.toGMTString() : "") +
((path) ? "; path=" + path : "") +
((domain) ? "; domain=" + domain : "") +
((secure) ? "; secure" : "");
}
/**
* Gets the value of the specified cookie.
*
* name Name of the desired cookie.
*
* Returns a string containing value of specified cookie,
* or null if cookie does not exist.
*/
function getCookie(name)
{
var dc = document.cookie;
var prefix = name + "=";
var begin = dc.indexOf("; " + prefix);
if (begin == -1)
{
begin = dc.indexOf(prefix);
if (begin != 0) return null;
}
else
{
begin += 2;
}
var end = document.cookie.indexOf(";", begin);
if (end == -1)
{
end = dc.length;
}
return unescape(dc.substring(begin + prefix.length, end));
}
/**
* Deletes the specified cookie.
*
* name name of the cookie
* [path] path of the cookie (must be same as path used to create cookie)
* [domain] domain of the cookie (must be same as domain used to create cookie)
*/
function deleteCookie(name, path, domain)
{
if (getCookie(name))
{
var myDate=new Date();
myDate.setFullYear(2000,0,14);
setCookie(name, 1, myDate, '/');
// document.cookie = name + "=" +
// ((path) ? "; path=" + path : "") +
// ((domain) ? "; domain=" + domain : "") +
// "; expires=Thu, 01-Jan-70 00:00:01 GMT";
}
}
function populateModels(el, target, sel) {
gE(target).options.length = 0;
j = 0;
gE(target).options[j] = new Option("Toate modelele ...", 0);
j++;
// alert
if(el.value > 0) {
if(jsModels[el.value].length) {
for (var i = 0; i < jsModels[el.value].length; i++) {
if(jsModels[el.value][i]) {
gE(target).options[j] = new Option(jsModels[el.value][i], i);
if(sel == i) {
gE(target).options[j].selected = true;
}
j++;
}
}
}
}
}