Html 如何使用internet explorer中的数据URI作为URL?
我尝试使用的代码是Html 如何使用internet explorer中的数据URI作为URL?,html,internet-explorer,notepad,Html,Internet Explorer,Notepad,我尝试使用的代码是 data:text/html, <body contenteditable style="font: 2rem/1.5 monospace; max-width:60rem; margin:0 auto; padding:4rem;"> data:text/html, 我在网上找到的。我想
data:text/html,
<body contenteditable style="font: 2rem/1.5 monospace;
max-width:60rem;
margin:0 auto;
padding:4rem;">
data:text/html,
我在网上找到的。我想把它放在URL上,然后按enter键,但只适用于Chrome、Firefox和Opera。在IE上不行。我怎样才能在IE上做记事本
更多信息:
我使用的是工作电脑,我无法访问任何网站或程序。没有文件浏览器,右键单击上下文菜单,只有IE。您可以尝试使用javascript引擎创建类似的执行
从URL栏:
javascript:window.document.write(“”);
如果复制并粘贴,则需要手动在其前面键入javascript:,因为浏览器会在粘贴时修剪该部分内容
如果要以编辑器的形式执行新窗口,请尝试以下操作:
<script>
function myFunction() {
var myWindow = window.open("", "MyEditorWindow");
myWindow.document.write("<body contenteditable style=\"font: 2em/1.5 monospace;padding:40px;\">");
}
</script>
函数myFunction(){
var myWindow=window.open(“,“MyEditorWindow”);
myWindow.document.write(“”);
}
看看这个
- IE不支持数据URI标记。因此,您必须在javascript或html标记中使用它
- IE不支持将REM CSS3属性REM作为一个单元。因此,您必须使用em或px李>
顺便说一句。直到我将该字符添加到末尾,它才起作用。我尝试在一个新选项卡中打开一个数据URI,该选项卡的大小远低于32 KB,但它不会呈现。我尝试提取画布图表,因为您误解了该链接。Internet Explorer确实支持数据:
URI,但不作为链接位置。@Quentin在2014年回答时,Internet浏览器在2014年不支持。@rajeshujade-对数据:
方案URL的支持自回答之前就没有改变过。Internet Explorer的最新版本于2013年发布。
<script>
function myFunction() {
var myWindow = window.open("", "MyEditorWindow");
myWindow.document.write("<body contenteditable style=\"font: 2em/1.5 monospace;padding:40px;\">");
}
</script>