Write a link that calls a javascript function. Use the information from the database to define width and height. Javascript would look something like this:
function ONWindowO(page){
OpenWin = window.open(page, "CtrlWindow", "resizable=no, toolbar=no, menubar=no, location=no, scrollbars=no, status=yes, height=<?=$db_height?>, width=<?=$db_width?>");
}
Good luck