function displayPopImg( linkObj )
{
    bbPopWin = window.open( "", "bbPopper", "scrollbars=0,top=20,left=20,width=350,height=350,resizable=0" );
    bbPopWin.document.open();
    bbPopWin.document.write
    (   '<html><head><title>Danby Concept Consolidated Pty Ltd.</title>'
      + '<meta http-equiv="imagetoolbar" content="no" />'
      + '<style type="text/css">BODY{margin:0}</style>'
      + '<script language="JavaScript" type="text/javascript" src="/danby.js"></script>'
      + '</head>'
      + '<body oncontextmenu="return false" onload="resizeWinOnImg(document.bbOrigPhoto);">'
      + '<img name="bbOrigPhoto" id="bbOrigPhoto" src="' + linkObj.src + '" />'
      + '</body></html>'
    );
    bbPopWin.document.close();
    bbPopWin.focus();
}

function resizeWinOnImg( imgObj )
{
    // detect img dimensions
    var iw = imgObj.width;
    var ih = imgObj.height;
    if ( iw == null || ih == null ) { return; }
    // detect user screen resolution
    var sw = screen.availWidth;
    var sh = screen.availHeight;
    if( sw == null || sh == null ) { return; }
    // resize window
    
    window.resizeTo( iw+8, ih+32 );
    //window.scrollbars.visible = false;
}

