I would use
position: fixed;
top: 50%;
left: 50%;
margin-left: -(dialogwidth/2);
margin-top: -(dialogheight/2);
but with this solution and the browser viewport size is smaller than your dialog box, portions of the dialog will not be accessible from the top and left because they are outside the viewport. Therefore, you need to decide if the size of the dialogs is right for you.
(CSS , , , , .)
Edit:
, IE6, - :
#dialog { position: absolute; }
#dialog[id] { position: fixed; }
IE6 , IE6 , ββ . ( . . .)