function aw(cim,cel) {
    ujwin=window.open(cim+'view_adatlap.php?id='+cel,'','width=870, height=640, resizable=yes, scrollbars=yes, menubar=no');
    ujwin.opener=self;
}

function nw(cim,w,h) {
    opcio='resizable=yes, scrollbars=yes, menubar=no';
    if (w) opcio='width='+w+', '+opcio;
    if (h) opcio='height='+h+', '+opcio;
    ujwin=window.open(cim,'',opcio);
    ujwin.opener=self;
}

function uw(uid,abspath) {
    if (!abspath) abspath='';
    var w=628;
    var h=465;
    var winl=(screen.width-w)/2;
    var wint=(screen.height-h)/2;
    ujwin=window.open(abspath+'view_msgsend.php?userid='+uid,'','width='+w+', height='+h+', left='+winl+', top='+wint+', resizable=yes, scrollbars=no, menubar=no');
    ujwin.opener=self;
//    return false;
}

function ujw(cim,w,h) {
    var winl=(screen.width-w)/2;
    var wint=(screen.height-h)/2;
    ujwin=window.open(cim,'','width='+w+', height='+h+', left='+winl+', top='+wint+', resizable=yes, scrollbars=no, menubar=no');
    ujwin.opener=self;
//    return false;
}

function ew(uid) {
    var w=615;
    var h=460;
    var winl=(screen.width-w)/2;
    var wint=(screen.height-h)/2;
    ujwin=window.open('view_suggest.php?userid='+uid,'','width='+w+', height='+h+', left='+winl+', top='+wint+', resizable=yes, scrollbars=no, menubar=no');
    ujwin.opener=self;
//    return false;
}

var cwin;

function cw(cim) {
    var w=780;
    var h=550;
    var winl=(screen.width-w)/2;
    var wint=(screen.height-h)/2;
    if ( (!cwin) || (!cwin.open) || (cwin.closed) ) {
	cwin=window.open(cim,'erinteschat','width='+w+', height='+h+', left='+winl+', top='+wint+', resizable=yes, scrollbars=no, menubar=no');
	cwin.opener=self;
    } else {
	cwin.focus();
    }
}

function SetParent() {
    if (parent.opener) {
	parent.opener.cwin=this;
	setTimeout("SetParent();",1000);
    }
}

/*function getObject(obj) {
  var theObj;
  if(document.all) {
    if(typeof obj=="string") {
      return document.all(obj);
    } else {
      return obj.style;
    }
  }
  if(document.getElementById) {
    if(typeof obj=="string") {
      return document.getElementById(obj);
    } else {
      return obj.style;
    }
  }
  return null;
}

*/
