// JavaScript Document
function _popup(page, width, height) {
	_popupS(page, width, height, "no");
}

function _popupS(page, width, height, scroll) {
	window.open(page,'popup','width='+width+', height='+height+', scrollbars='+scroll+', toolbar=no, location=no, resizable=no');
	return false;
}
/*===================== POPUP CENTER WINDOWS PAGE ==========================*/
/*
 * OOP in Javascript
 * Popup Window
 */
var OpenWindow = function (url, name, width, height, property) {
		this.x = (screen.width - width) / 2;
		/* Kho?ng cch c?a Popup t?i l? tri
		  * screen.width: l?y width c?a mn hnh hi?n t?i
		 * width: chi?u r?ng popup
		 */
		this.y = (screen.height - height - 60) / 2;
		/* Kho?ng cch c?a Popup t?i l? trn
		  * screen.height: l?y height c?a mn hnh hi?n t?i
		 * height: chi?u cao c?a popup
		 * -60: Tr? di kch thu?t thanh Taskbar
		 */
		property = 'top=' + this.y + ',left=' + this.x + ',width=' + width + ',height=' + height + ',' + property;
		/* K?t h?p cc thu?c tnh c?a popup
		  * 'top=100, left=100, height=500, width=400, scrollbars=yes, resizable=no'
		 */
		newwindow=window.open(url, name, property);
		/*
		 * Open Popup
		 */
		if (window.focus) {
				newwindow.focus();
		}
		/*
		 * Khi popup dang m?, n?u user click m? l?n n?a th active l?i c?a s? d m?
		 */
		return false;
		/*
		 * Return false: Ch? m? popup khng th?c thi link trong href.
		 */
}

