Here is a very short tutorial on centering a Flash movie in a browser from Flash. No JS or HTML needed.
Code:
function openCenteredWin(url,wid,hei) {
getURL("java script:cntPop=window.open('" + url + "','popupName','width=" + wid + ",height=" + hei + "');cntPop.moveTo((screen.width-" + wid + ")/2,(screen.height-" + hei + ")/2);void(0);");
}
and when you want to open a popup from your flash, just use:
Code:
_root.openCenteredWin("yourPage.html",720,720);
// where first parameter is URL to open, second is width and third is height
and that's it... no HTML/JS needed at all. Even if you open directly your .swf in the browser, it will still work.