function newWindow(url, wname, width, height) {
    var features = "height=" + height + ",width=" + width +
                   ",status=no,toolbar=no,menubar=no,location=no";
    window.open(url, wname, features);
}

function closeWindow() {
    window.close();
}