Created
December 11, 2013 20:18
-
-
Save Gozala/7917694 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let XUL_NS = "http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"; | |
let HTML_NS = "http://www.w3.org/1999/xhtml"; | |
let toolbar = document.createElementNS(XUL_NS, "toolbar"); | |
toolbar.setAttribute("collapsed", false); | |
toolbar.setAttribute("style", "height: 80px;"); | |
let toolbox = document.getElementById("navigator-toolbox"); | |
toolbox.appendChild(toolbar); | |
let iframe = document.createElementNS(HTML_NS, "iframe"); | |
iframe.setAttribute("srcdoc", "<iframe src='resource:///chrome/browser/content/browser/aboutRobots.xhtml'/>"); | |
//iframe.setAttribute("src", "resource:///chrome/browser/content/browser/aboutRobots.xhtml") | |
// type isn't recognized by HTML iframes so we set a sandbox instead. | |
// iframe.setAttribute("type", "content"); | |
//iframe.setAttribute("sandbox", "allow-scripts "); | |
iframe.setAttribute("mozbrowser", ""); | |
//iframe.setAttribute("mozframetype", "content") | |
// transparen isn't recognized by HTML iframes so we set seamless instead. | |
// iframe.setAttribute("transparent", true); | |
iframe.setAttribute("seamless", ""); | |
toolbar.appendChild(iframe); | |
// Security Error: Content at about:srcdoc may not load or link to resource:///chrome/browser/content/browser/aboutRobots.xhtml. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment