2003-06-21 02:41:42 +04:00
|
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
|
|
|
|
"http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
|
|
|
|
<html>
|
|
|
|
<head>
|
|
|
|
<title>Control Frame</title>
|
|
|
|
</head>
|
|
|
|
|
2010-03-03 13:12:28 +03:00
|
|
|
<script type="application/javascript">
|
2003-06-21 02:41:42 +04:00
|
|
|
|
2003-07-09 01:08:23 +04:00
|
|
|
const nsILayoutDebuggingTools = Components.interfaces.nsILayoutDebuggingTools;
|
|
|
|
var gDebugTools;
|
|
|
|
|
|
|
|
function Init()
|
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
|
|
|
gDebugTools = Components.classes["@mozilla.org/layout-debug/layout-debuggingtools;1"].createInstance(nsILayoutDebuggingTools);
|
|
|
|
gDebugTools.init(window.frames.pageframe);
|
|
|
|
}
|
2003-06-21 02:41:42 +04:00
|
|
|
|
|
|
|
function SetShowFrameBorders(inShow)
|
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
2003-07-09 01:08:23 +04:00
|
|
|
gDebugTools.visualDebugging = inShow;
|
2003-06-21 02:41:42 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
function SetShowEventTargetBorders(inShow)
|
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
2003-07-09 01:08:23 +04:00
|
|
|
gDebugTools.visualEventDebugging = inShow;
|
2003-06-21 02:41:42 +04:00
|
|
|
}
|
|
|
|
|
2003-07-09 01:08:23 +04:00
|
|
|
function SetShowReflowStats(inShow)
|
2003-06-21 02:41:42 +04:00
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
2003-07-09 01:08:23 +04:00
|
|
|
gDebugTools.reflowCounts = inShow;
|
2003-06-21 02:41:42 +04:00
|
|
|
}
|
|
|
|
|
2003-07-09 01:08:23 +04:00
|
|
|
function DumpFrames()
|
2003-06-21 02:41:42 +04:00
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
2003-07-09 01:08:23 +04:00
|
|
|
gDebugTools.dumpFrames();
|
2003-06-21 02:41:42 +04:00
|
|
|
}
|
|
|
|
|
2003-07-09 01:08:23 +04:00
|
|
|
function DumpContent()
|
2003-06-21 02:41:42 +04:00
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
2003-07-09 01:08:23 +04:00
|
|
|
gDebugTools.dumpContent();
|
2003-06-21 02:41:42 +04:00
|
|
|
}
|
|
|
|
|
2003-07-09 01:08:23 +04:00
|
|
|
function DumpViews()
|
2003-06-21 02:41:42 +04:00
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
2003-07-09 01:08:23 +04:00
|
|
|
gDebugTools.dumpViews();
|
2003-06-21 02:41:42 +04:00
|
|
|
}
|
|
|
|
|
2003-07-09 01:08:23 +04:00
|
|
|
function DumpWebShells()
|
2003-06-21 02:41:42 +04:00
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
2003-07-09 01:08:23 +04:00
|
|
|
gDebugTools.dumpWebShells();
|
2003-06-21 02:41:42 +04:00
|
|
|
}
|
|
|
|
|
|
|
|
function InputKey(inEvent)
|
|
|
|
{
|
2014-02-15 04:57:39 +04:00
|
|
|
if (inEvent.keyCode == KeyEvent.DOM_VK_RETURN)
|
2003-06-21 02:41:42 +04:00
|
|
|
{
|
|
|
|
var pageFrame = window.frames.pageframe;
|
|
|
|
pageFrame.location.href = document.dumpform.urlfield.value;
|
|
|
|
inEvent.preventDefault(); // avoid form submit on hitting return
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function IframeLoaded()
|
|
|
|
{
|
|
|
|
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
|
|
|
|
document.dumpform.urlfield.value = window.frames.pageframe.location.href;
|
|
|
|
}
|
|
|
|
</script>
|
|
|
|
|
2003-07-09 01:08:23 +04:00
|
|
|
<body onload="Init()">
|
2003-06-21 02:41:42 +04:00
|
|
|
|
|
|
|
<form name="dumpform">
|
|
|
|
<div style="margin-bottom: 5px">
|
|
|
|
URL: <input type="text" size="100" name="urlfield" value="http://www.mozilla.org" onkeypress="InputKey(event)"></input>
|
|
|
|
</div>
|
|
|
|
<div>
|
2003-07-09 01:08:23 +04:00
|
|
|
<input type="button" value="Dump Frames" onclick="DumpFrames()">
|
|
|
|
<input type="button" value="Dump Content" onclick="DumpContent()">
|
|
|
|
<input type="button" value="Dump Views" onclick="DumpViews()">
|
|
|
|
<input type="button" value="Dump WebShells" onclick="DumpWebShells()">
|
2003-06-21 02:41:42 +04:00
|
|
|
|
|
|
|
<input type="checkbox" id="showBordersCheck" name="showBordersCheck"
|
|
|
|
onchange="SetShowFrameBorders(document.dumpform.showBordersCheck.checked)"></input>
|
|
|
|
<label for="showBordersCheck">Show Frame Borders</label>
|
|
|
|
</div>
|
|
|
|
</form>
|
|
|
|
|
|
|
|
<iframe name="pageframe" style="border: 1px solid black; width:800px; height:800px;" onload="IframeLoaded()"></iframe>
|
|
|
|
|
|
|
|
</body>
|
|
|
|
</html>
|
|
|
|
|