html - CKeditor - html Onclick 属性不起作用

标签 html ckeditor ckeditor4.x

我使用下面的代码在新窗口中打开 Google,但在 CKeditor 中这不起作用。

<div align="center"><button onclick="window.open('http://google.com','_self')">Click here to open <b> google </b> 
</button></div>

最佳答案

将_self更改为_blank

    <div align="center"><button onclick="window.open('http://google.com','_blank')">Click here to open <b> google </b>
    </button></div>

这应该有效。

关于html - CKeditor - html Onclick 属性不起作用,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35220058/

相关文章:

javascript - CKeditor 默认选择图片对话框中的上传选项卡

javascript - CKeditor insertHtml/insertElement IE8问题

javascript - Ckeditor 初始禁用小部件按钮状态

internet-explorer - CKEditor-IE中对setReadOnly的权限被拒绝

html - 使用 contains() 获取具有包含特定子字符串的 'src' 属性的 iframe 元素的 Xpath

html - 我怎样才能使侧边栏粘住?

javascript - 使用 CKEditor 的动态主体颜色

javascript - 工具栏配置不适用于内联 CKEditor

html - 如何测试 CSS/HTML/jQuery?

javascript - 如何制作按钮/链接以在 &lt;iframe&gt; 而不是页面中显示源代码?