/**
 * openPlayer(sURL, iWidth, iHeight)
 *
 * Open the 'embedded' player with the given url.
 *
 * @version 1.0
 * @access  public
 * @author  A.J. de Vries
 * @param   [string]  sURL    - the url to the player with the movie as argument (GET).
 * @param   [integer] iWidth  - the width of the player window.
 * @param   [integer] iHeight - the height of the player window. 
 * @return  [void]
 */
function openPlayer(sURL, iWidth, iHeight, aflID) {
	if(sURL != '') {
		iWidth = (iWidth) ? iWidth : 800;
		iHeight = (iHeight) ? iHeight : 612;
		
		var iLeftPos = (screen.availWidth - iWidth) / 2;
		var iTopPos = (screen.availHeight - iHeight) / 2; 
		var sOpts = "toolbar=no, status=no, location=no, menubar=no, resizable=yes,";
		    sOpts += " width=" + iWidth + ", height=" + iHeight + ", scrollbars=no,";
		    sOpts += "top=" + iTopPos + ",left=" + iLeftPos;
		var eDialog = window.open("", "player", sOpts);
		eDialog.location = sURL;
		eDialog.focus();
	}
	return false;
}
