diff --git a/ChangeLog b/ChangeLog index 40c862c39..b32e2b02b 100755 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,12 @@ phpMyAdmin - Changelog $Id$ $Source$ +2003-07-08 Garvin Hicking + * tbl_query_box.php3, footer.inc.php3: Removed any 'top.' DOM reference. + This enables phpMyAdmin to be used within a frameset without trying + to escape out of the security JS-sandbox zone. Tested with IE6, Mozilla + 1.4 and IE5.5. + 2003-07-08 Marc Delisle * libraries/sqlparser.lib.php3, sql.php3: bug 762213, incorrect row count for MySQL 4.1 subqueries; diff --git a/footer.inc.php3 b/footer.inc.php3 index d80c2dc6e..563e4c76f 100755 --- a/footer.inc.php3 +++ b/footer.inc.php3 @@ -18,7 +18,7 @@ if ($cfg['QueryFrame'] && $cfg['QueryFrameJS']) { if ($cfg['QueryFrameDebug']) { ?> document.writeln("Updating query window. DB: , Table:
"); - document.writeln("Window: " + top.frames.queryframe.querywindow.location + "
"); + document.writeln("Window: " + parent.frames.queryframe.querywindow.location + "
"); @@ -26,31 +26,31 @@ if ($cfg['QueryFrame'] && $cfg['QueryFrameJS']) { - if (top.frames.queryframe && top.frames.queryframe.document && top.frames.queryframe.document.queryframeform) { - top.frames.queryframe.document.queryframeform.db.value = ""; - top.frames.queryframe.document.queryframeform.table.value = ""; + if (parent.frames.queryframe && parent.frames.queryframe.document && parent.frames.queryframe.document.queryframeform) { + parent.frames.queryframe.document.queryframeform.db.value = ""; + parent.frames.queryframe.document.queryframeform.table.value = ""; } function reload_querywindow () { - if (top.frames.queryframe && top.frames.queryframe.querywindow && !top.frames.queryframe.querywindow.closed && top.frames.queryframe.querywindow.location) { - Query Window can be updated.
");' : ''); ?> + if (parent.frames.queryframe && parent.frames.queryframe.querywindow && !parent.frames.queryframe.querywindow.closed && parent.frames.queryframe.querywindow.location) { + Query Window can be updated.
");' : ''); ?> - if (!top.frames.queryframe.querywindow.document.sqlform.LockFromUpdate.checked) { - top.frames.queryframe.querywindow.document.querywindow.db.value = ""; - top.frames.queryframe.querywindow.document.querywindow.query_history_latest_db.value = ""; - top.frames.queryframe.querywindow.document.querywindow.table.value = ""; - top.frames.queryframe.querywindow.document.querywindow.query_history_latest_table.value = ""; + if (!parent.frames.queryframe.querywindow.document.sqlform.LockFromUpdate.checked) { + parent.frames.queryframe.querywindow.document.querywindow.db.value = ""; + parent.frames.queryframe.querywindow.document.querywindow.query_history_latest_db.value = ""; + parent.frames.queryframe.querywindow.document.querywindow.table.value = ""; + parent.frames.queryframe.querywindow.document.querywindow.query_history_latest_table.value = ""; - + - top.frames.queryframe.querywindow.document.querywindow.submit(); + parent.frames.queryframe.querywindow.document.querywindow.submit(); } '; - top.frames.queryframe.querywindow=window.open(new_win_url, '','toolbar=0,location=1,directories=0,status=1,menubar=0,scrollbars=yes,resizable=yes,width=,height='); + parent.frames.queryframe.querywindow=window.open(new_win_url, '','toolbar=0,location=1,directories=0,status=1,menubar=0,scrollbars=yes,resizable=yes,width=,height='); - if (!top.frames.queryframe.querywindow.opener) { - top.frames.queryframe.querywindow.opener = top.frames.queryframe; + if (!parent.frames.queryframe.querywindow.opener) { + parent.frames.queryframe.querywindow.opener = parent.frames.queryframe; } // reload_querywindow(); @@ -91,7 +91,7 @@ if ($cfg['QueryFrame'] && $cfg['QueryFrameJS']) { - if (top.frames.queryframe && top.frames.queryframe.querywindow && !top.frames.queryframe.querywindow.closed && top.frames.queryframe.querywindow.location) { + if (parent.frames.queryframe && parent.frames.queryframe.querywindow && !parent.frames.queryframe.querywindow.closed && parent.frames.queryframe.querywindow.location) { self.focus(); } = 7)) - ? "\n" . ' onfocus="if (typeof(document.layers) == \'undefined\' || typeof(textarea_selected) == \'undefined\') {textarea_selected = 1; this.form.elements[\'sql_query\'].select();}"' + ? "\n" . ' onfocus="if (typeof(document.layers) == \'undefined\' || typeof(textarea_selected) == \'undefined\') {textarea_selected = 1; document.sqlform.elements[\'sql_query\'].select();}"' : ''; $auto_sel .= ' ' . $locking; @@ -90,7 +90,7 @@ if ($cfg['QueryFrame'] && $cfg['QueryFrameJS'] && isset($is_inside_querywindow) ?>