document.execcommand saveas;为什么在非IE内核浏览器中不起作用

后使用快捷导航没有帐号?
只需一步,快速开始
查看: 388|回复: 6
在线时间693 小时经验值614 最后登录注册时间帖子阅读权限60UID246715
大学本科, 积分 614, 距离下一级还需 86 积分
TA的每日心情开心 15:44签到天数: 1 天[LV.1]初来乍到
G币214 最后登录注册时间
马上注册,结交更多机友,下载更多应用,让你轻松玩转手机。
已有帐号?   下载游戏和软件,请【】进入机锋市场!
今天为什么我用非ie内核浏览器无法下载附件?老是报 attachment_nonexistence?
chrome和opera都是这样,用ie就没问题,chrome的ietab也可以下载
刚发现附件也无法上传
21:14 上传
快快快快快快快快快快快
在线时间350 小时经验值611 最后登录注册时间帖子阅读权限60UID476599
大学本科, 积分 611, 距离下一级还需 89 积分
TA的每日心情慵懒 11:08签到天数: 15 天[LV.4]偶尔看看III
G币196 最后登录注册时间
同样啊{:122_373:}
在线时间370 小时经验值619 最后登录注册时间帖子阅读权限60UID38082
大学本科, 积分 619, 距离下一级还需 81 积分
TA的每日心情开心 09:05签到天数: 3 天[LV.2]偶尔看看I
G币1694 最后登录注册时间
下载附件出错&&唉
食堂三菜:荤菜-炒鸡蛋,小荤-黄瓜炒鸡蛋,素菜-炒黄瓜。谁与争锋。
在线时间311 小时经验值184 最后登录注册时间帖子阅读权限40UID637743
高中生, 积分 184, 距离下一级还需 16 积分
TA的每日心情慵懒 02:20签到天数: 1 天[LV.1]初来乍到
G币228 最后登录注册时间
等了好多天~還是一樣無法下載喔!
付了好多金幣= =
在线时间450 小时经验值342 最后登录注册时间帖子阅读权限50UID1863793
大学专科, 积分 342, 距离下一级还需 58 积分
TA的每日心情开心 15:15签到天数: 1 天[LV.1]初来乍到
G币7 最后登录注册时间
对啊啊气死人了
在线时间3 小时经验值8 最后登录注册时间帖子阅读权限10UID6400547
幼儿园, 积分 8, 距离下一级还需 7 积分
该用户从未签到
G币15 最后登录注册时间
本帖最后由 天空︻︼-- 于
13:04 编辑
是的,有解决方案?头大的
300 字节以内
不支持自定义 Discuz! 代码
在线时间3460 小时经验值11753 最后登录注册时间帖子阅读权限1UID251783
头像被屏蔽
TA的每日心情开心 14:59签到天数: 3 天[LV.2]偶尔看看I
G币16772 最后登录注册时间
提示: 作者被禁止或删除 内容自动屏蔽
签名被屏蔽
Powered bydocument.execCommand()的用法小结
字体:[ ] 类型:转载 时间:
本篇文章主要是对document.execCommand()的用法进行了详细的介绍,需要的朋友可以过来参考下,希望对大家有所帮助
首先要说明的是在firefox下支持不好。2D-Position 允许通过拖曳移动绝对定位的对象。 AbsolutePosition 设定元素的 position 属性为“absolute”(绝对)。 BackColor 设置或获取当前选中区的背景颜色。 BlockDirLTR 目前尚未支持。 BlockDirRTL 目前尚未支持。 Bold 切换当前选中区的粗体显示与否。 BrowseMode 目前尚未支持。 Copy 将当前选中区复制到剪贴板。 CreateBookmark 创建一个书签锚或获取当前选中区或插入点的书签锚的名称。 CreateLink 在当前选中区上插入超级链接,或显示一个对话框允许用户指定要为当前选中区插入的超级链接的 URL。 Cut 将当前选中区复制到剪贴板并删除之。 Delete 删除当前选中区。 DirLTR 目前尚未支持。 DirRTL 目前尚未支持。 EditMode 目前尚未支持。 FontName 设置或获取当前选中区的字体。 FontSize 设置或获取当前选中区的字体大小。 ForeColor 设置或获取当前选中区的前景(文本)颜色。 FormatBlock 设置当前块格式化标签。 Indent 增加选中文本的缩进。 InlineDirLTR 目前尚未支持。 InlineDirRTL 目前尚未支持。 InsertButton 用按钮控件覆盖当前选中区。 InsertFieldset 用方框覆盖当前选中区。 InsertHorizontalRule 用水平线覆盖当前选中区。 InsertIFrame 用内嵌框架覆盖当前选中区。 InsertImage 用图像覆盖当前选中区。 InsertInputButton 用按钮控件覆盖当前选中区。 InsertInputCheckbox 用复选框控件覆盖当前选中区。 InsertInputFileUpload 用文件上载控件覆盖当前选中区。 InsertInputHidden 插入隐藏控件覆盖当前选中区。 InsertInputImage 用图像控件覆盖当前选中区。 InsertInputPassword 用密码控件覆盖当前选中区。 InsertInputRadio 用单选钮控件覆盖当前选中区。 InsertInputReset 用重置控件覆盖当前选中区。 InsertInputSubmit 用提交控件覆盖当前选中区。 InsertInputText 用文本控件覆盖当前选中区。 InsertMarquee 用空字幕覆盖当前选中区。 InsertOrderedList 切换当前选中区是编号列表还是常规格式化块。 InsertParagraph 用换行覆盖当前选中区。 InsertSelectDropdown 用下拉框控件覆盖当前选中区。 InsertSelectListbox 用列表框控件覆盖当前选中区。 InsertTextArea 用多行文本输入控件覆盖当前选中区。 InsertUnorderedList 切换当前选中区是项目符号列表还是常规格式化块。 Italic 切换当前选中区斜体显示与否。 JustifyCenter 将当前选中区在所在格式化块置中。 JustifyFull 目前尚未支持。 JustifyLeft 将当前选中区所在格式化块左对齐。 JustifyNone 目前尚未支持。 JustifyRight 将当前选中区所在格式化块右对齐。 LiveResize 迫使 MSHTML 编辑器在缩放或移动过程中持续更新元素外观,而不是只在移动或缩放完成后更新。 MultipleSelection 允许当用户按住 Shift 或 Ctrl 键时一次选中多于一个站点可选元素。 Open 打开。 Outdent 减少选中区所在格式化块的缩进。 OverWrite 切换文本状态的插入和覆盖。 Paste 用剪贴板内容覆盖当前选中区。 PlayImage 目前尚未支持。 Print 打开打印对话框以便用户可以打印当前页。 Redo 重做。 Refresh 刷新当前文档。 RemoveFormat 从当前选中区中删除格式化标签。 RemoveParaFormat 目前尚未支持。 SaveAs 将当前 Web 页面保存为文件。 SelectAll 选中整个文档。 SizeToControl 目前尚未支持。 SizeToControlHeight 目前尚未支持。 SizeToControlWidth 目前尚未支持。 Stop 停止。 StopImage 目前尚未支持。 StrikeThrough 目前尚未支持。 Subscript 目前尚未支持。 Superscript 目前尚未支持。 UnBookmark 从当前选中区中删除全部书签。 Underline 切换当前选中区的下划线显示与否。 Undo 撤消。 Unlink 从当前选中区中删除全部超级链接。 Unselect 清除当前选中区的选中状态。
例1:isNaN是测试是否为数值型 ,限制输入只能为数值如:,允许最多有一个小数点 代码如下:&input type="text" name="text" onkeyup="if(isNaN(value))execCommand('undo')" /&例2: 代码如下:&input type=button value=剪切 onclick=document.execCommand('Cut')&&input type=button value=拷贝 onclick=document.execCommand('Copy')&&input type=button value=粘贴 onclick=document.execCommand('Paste')&&input type=button value=撤消 onclick=document.execCommand('Undo')&&input type=button value=重做 onclick=document.execCommand('Redo') id=button2 name=button2&&input&&input type=button value=删除 onclick=document.execCommand('Delete')&&input type=button value=黑体 onclick=document.execCommand('Bold')&&input type=button value=斜体 onclick=document.execCommand('Italic')&&input type=button value=下划线 onclick=document.execCommand('Underline')&&input type=button value=停止 onclick=document.execCommand('stop')&&input type=button value=保存 onclick=document.execCommand('SaveAs')&&input type=button value=另存为 onclick=document.execCommand('Saveas',false,'c:\\test.htm')&&input type=button value=字体 onclick=document.execCommand('FontName',false,fn)&&input type=button value=字体大小 onclick=document.execCommand('FontSize',false,fs)&&input type=button value=刷新 onclick=document.execCommand('refresh',false,0)&
您可能感兴趣的文章:
大家感兴趣的内容
12345678910
最近更新的内容
常用在线小工具document.execCommand
当文档对象被转换为设计模式的时候(选中,设置contentEditable等),文档对象提供了一个execCommand方法,通过给这这个方法传递参数命令可以操作可编辑区域的内容。这个方法的命令大多数是对文档选中区域的操作 (如bold, italics等), 也可以插入一个元素(如增加一个a链接) 或者修改一个完整行 (如缩进).。当元素被设置了contentEditable,通过执行execCommand 方法可以对当前活动元素进行很多操作。
bool = document.execCommand(aCommandName, aShowDefaultUI, aValueArgument)
,如果是 false 则表示操作不被支持或未被启用。
aCommandName
,命令的名称。可用命令列表请参阅
aShowDefaultUI
是否展示用户界面,一般为 false。Mozilla 没有实现。
aValueArgument
一些命令需要一些额外的参数值(如insertimage需要提供这个image的url)。默认为null。
Changes the document background color. In styleWithCss mode, it affects the background color of the containing block instead. This requires a
value string to be passed in as a value argument. Note that Internet Explorer uses this to set the text background color.修改文档的背景颜色。在styleWithCss模式下,则只影响容器元素的背景颜色。这需要一个 类型的字符串值作为参数传入。注意,IE浏览器用这个设置文字的背景颜色。
Toggles bold on/off for the selection or at the insertion point. Internet Explorer uses the
tag instead of .开启或关闭选中文字或插入点的粗体字效果。IE浏览器使用 标签,而不是标签。
contentReadOnly
Makes the content document either read-only or editable. This requires a boolean true/false to be passed in as a value argument. (Not supported by Internet Explorer.)
Copies the current selection to the clipboard. Conditions of having this behavior enabled vary from one browser to another, and have evolved over time. Check the compatibility table to determine if you can use it in your case.拷贝当前选中内容到剪贴板。启用这个功能的条件因浏览器不同而不同,而且不同时期,其启用条件也不尽相同。使用之前请检查浏览器兼容表,以确定是否可用。
createLink
Creates an anchor link from the selection, only if there is a selection. This requires the HREF URI string to be passed in as a value argument. The URI must contain at least a single character, which may be a white space. (Internet Explorer will create a link with a null URI value.)
Cuts the current selection and copies it to the clipboard. Conditions of having this behavior enabled vary from one browser to another, and have evolved over time. Check the compatibility table for knowing if you can use it in your case.
decreaseFontSize
tag around the selection or at the insertion point. (Not supported by Internet Explorer.)
Deletes the current selection.
enableInlineTableEditing
Enables or disables the table row and column insertion and deletion controls. (Not supported by Internet Explorer.)
enableObjectResizing
Enables or disables the resize handles on images and other resizable objects. (Not supported by Internet Explorer.)
Changes the font name for the selection or at the insertion point. This requires a font name string ("Arial" for example) to be passed in as a value argument.
Changes the font size for the selection or at the insertion point. This requires an HTML font size (1-7) to be passed in as a value argument.
Changes a font color for the selection or at the insertion point. This requires a color value string to be passed in as a value argument.
formatBlock
Adds an HTML block-style tag around the line containing the current selection, replacing the block element containing the line if one exists (in Firefox, BLOCKQUOTE is the exception - it will wrap any containing block element). Requires a tag-name string to be passed in as a value argument. Virtually all block style tags can be used (eg. "H1", "P", "DL", "BLOCKQUOTE"). (Internet Explorer supports only heading tags H1 - H6, ADDRESS, and PRE, which must also include the tag delimiters & &, such as "&H1&".)
forwardDelete
Deletes the character ahead of the 's position.
It is the same as hitting the delete key.
Adds a heading tag around a selection or insertion point line. Requires the tag-name string to be passed in as a value argument (i.e. "H1", "H6"). (Not supported by Internet Explorer and Safari.)
hiliteColor
Changes the background color for the selection or at the insertion point. Requires a color value string to be passed in as a value argument. UseCSS must be turned on for this to function. (Not supported by Internet Explorer.)
increaseFontSize
Adds a BIG tag around the selection or at the insertion point. (Not supported by Internet Explorer.)
Indents the line containing the selection or insertion point. In Firefox, if the selection spans multiple lines at different levels of indentation, only the least indented lines in the selection will be indented.
insertBrOnReturn
Controls whether the Enter key inserts a br tag or splits the current block element into two. (Not supported by Internet Explorer.)
insertHorizontalRule
Inserts a horizontal rule at the insertion point (deletes selection).
insertHTML
Inserts an HTML string at the insertion point (deletes selection). Requires a valid HTML string to be passed in as a value argument. (Not supported by Internet Explorer.)
insertImage
Inserts an image at the insertion point (deletes selection). Requires the image SRC URI string to be passed in as a value argument. The URI must contain at least a single character, which may be a white space. (Internet Explorer will create a link with a null URI value.)
insertOrderedList
Creates a numbered ordered list for the selection or at the insertion point.
insertUnorderedList
Creates a bulleted unordered list for the selection or at the insertion point.
insertParagraph
Inserts a paragraph around the selection or the current line. (Internet Explorer inserts a paragraph at the insertion point and deletes the selection.)
insertText
Inserts the given plain text at the insertion point (deletes selection).
在光标插入点开启或关闭斜体字。 (Internet Explorer 使用 EM 标签,而不是 I )
justifyCenter
Centers the selection or insertion point.
justifyFull
Justifies the selection or insertion point.
justifyLeft
Justifies the selection or insertion point to the left.
justifyRight
Right-justifies the selection or the insertion point.
Outdents the line containing the selection or insertion point.
在光标位置粘贴剪贴板的内容,如果有被选中的内容,会被替换。剪贴板功能必须在 user.js 配置文件中启用。参阅 [1].
重做被撤销的操作。
removeFormat
Removes all formatting from the current selection.
选中编辑区里的全部内容。
strikeThrough
在光标插入点开启或关闭删除线。
在光标插入点开启或关闭下角标。
superscript
在光标插入点开启或关闭上角标。
在光标插入点开启或关闭下划线。
撤销最近执行的命令。
Removes the anchor tag from a selected anchor link.
Toggles the use of HTML tags or CSS for the generated markup. Requires a boolean true/false as a value argument. NOTE: This argument is logically backwards (i.e. use false to use CSS, true to use HTML). (Not supported by Internet Explorer.) This use the styleWithCSS command instead.
styleWithCSS
用这个取代 useCSS 命令。 argument works as expected, i.e. true modifies/generates style attributes in markup, false generates formatting elements.
An example of
it on CodePen.
Specifications
Specification
Editor's Draft
Initial definition
Browser compatibility
Firefox (Gecko)
Internet Explorer
Basic support
insertBrOnReturn
Chrome for Android
Firefox Mobile (Gecko)
Opera Mobile
Safari Mobile
Basic support
insertBrOnReturn
[1] 在 Firefox 41 之前,剪贴板功能需要在 user.js 配置文件中启用。参阅 。命令若未被支持或启用,execCommand 会抛出异常,而不是返回 false。自 Firefox 41 开始,只要是在能够创建窗口的事件回调函数里(半可信脚本里),剪贴板功能都是默认开启的。
with bugs related to document.execCommand.?
文档标签和贡献者
&此页面的贡献者:
&最后编辑者:
Jun 28, :22 AM
execCommand
其他语言:
中文 (简体)
English (US)
Русский查看: 2005|回复: 4
易语言怎么操作非IE内核浏览器呢
阅读权限20
在线时间 小时
结帖率: (5/15)
怎么操作非IE内核浏览器呢
求助啊。操作GOOGLE&&就是易语言操作外部浏览器。
回答提醒:如果本帖被关闭无法回复,您有更好的答案帮助楼主解决,请发表至
可获得加分喔。友情提醒:本版被采纳的主题可在
帖子申请荣誉值,获得 1点 荣誉值,荣誉值可兑换终身vip用户组哦。快捷通道: →
阅读权限165
在线时间 小时
签到天数: 16 天结帖率: (17/29)
取到句柄 就可以操作了
阅读权限170
在线时间 小时
签到天数: 16 天结帖率: (63/77)
操作不了内核。。。
阅读权限20
在线时间 小时
结帖率: (5/15)
对,能取,不能填表。
阅读权限70
在线时间 小时
精易论坛 - 有你更精彩 /2
易语言自带组件无法满足开发需求?想让商业软件更专业更美观?SmartUI界面引擎作者将带领大家从零开始系统学习自绘,写自绘框架引擎,结合web来diy界面,快来围观~
Kirinoium-Collection 通用采集浏览器是一款专门针对网页填表,采集等业务而设计的一款网页浏览器。致力于解决目前易友所面临的新形式下复杂Web环境所带来的高昂开发成本和难以维护的问题。通过 Kirinoium-Collection 您可以轻松的完成各种复杂环境下的填表,采集作业,而无需为此投入时间以及人力物力。这将为您的项目节省大量成本,也更能在当前竞争激烈的软件行业中赢得更多机遇。
拒绝任何人以任何形式在本论坛发表与中华人民共和国法律相抵触的言论,本站内容均为会员发表,并不代表精易立场!
揭阳精易科技有限公司申明:我公司所有的培训课程版权归精易所有,任何人以任何方式翻录、盗版、破解本站培训课程,我们必将通过法律途径解决!
公司简介:揭阳市揭东区精易科技有限公司致力于易语言教学培训/易语言学习交流社区的建设与软件开发,多年来为中小企业编写过许许多多各式软件,并把多年积累的开发经验逐步录制成视频课程供学员学习,让学员全面系统化学习易语言编程,少走弯路,减少对相关技术的研究与摸索时间,从而加快了学习进度!
Powered by人次在我爱卡申请信用卡
人次申请贷款 255家 银行和金融机构授权合作
后使用快捷导航没有帐号?
查看: 2255|回复: 16
如果工行能支付非IE内核浏览器就完美了
阅读权限50
在线时间494 小时
金卡Ⅰ级, 经验值 1987, 距离下一级还需 1512 经验值
在线时间494 小时
其实工行已经很完美了,对我来说唯一的缺憾是不支持非IE内核浏览器。现在很少使用IE内核的浏览器了,基本上都是使用CHROME,所以网上支付上使用最多的是浦发银行,因为浦发是支持CHROME的。现在不太想用浦发了,和花旗分手后也没什么优势了,年费政策也不好,留下来的原因只是支付方便。
阅读权限80
在线时间761 小时
在线时间761 小时
呵呵,希望工行能听到我们的心声
阅读权限10
在线时间4 小时
在线时间4 小时
关键词&&ie tab
阅读权限50
在线时间171 小时
在线时间171 小时
嗯 嗯,这个要支持,呵呵
阅读权限50
在线时间494 小时
在线时间494 小时
dothemath 发表于
关键词&&ie tab
在LINUX系统上这样做也是没用的。
阅读权限120
在线时间2357 小时
我不是大猫。
在线时间2357 小时
hobboy 发表于
在LINUX系统上这样做也是没用的。
ie tab也只是调用IE内核。
深入灵魂的高傲可以被毁灭,却永远无法被征服。
阅读权限50
在线时间287 小时
在线时间287 小时
我用的金山猎豹浏览器,是根据CHROME基础上改动的,号称全球最快的浏览器,用上去确实快,而且支持所有网上的交易,网银,并且有网购赔付。推荐给大家。
QQ截图26.jpg (53 KB, 下载次数: 0)
22:45 上传
阅读权限50
在线时间297 小时
在线时间297 小时
一帮傻孩子,webkit是不是非ie呢,我不懂哦,不过用遨游可以进入任意一家。
一个人,一颗心,一生等待;一个人,一座城,一生心疼;一个人,一条路,一生孤单.
阅读权限40
在线时间143 小时
在线时间143 小时
傲游也是IE的外壳浏览器
阅读权限50
在线时间188 小时
在线时间188 小时
ICBC是可以用chrome的哦,我就是用chrome登工行网银的,装一个插件。
阅读权限50
在线时间188 小时
在线时间188 小时
ActiveX for Chrome 网银助手
装这个插件,工行网银就可以登了。
阅读权限50
在线时间193 小时
在线时间193 小时
难道还嫌被盗刷后银行的耍赖借口不够多吗?
珍惜生命 享受生活
阅读权限50
在线时间494 小时
在线时间494 小时
lany 发表于
ActiveX for Chrome 网银助手
装这个插件,工行网银就可以登了。
在LINUX系统是用不了的。
阅读权限80
在线时间1081 小时
在线时间1081 小时
真正支持非IE内核浏览器访问的网银还是少数的,大多数银行不支持。先不说别的,Linux平台的UKEY驱动就是个问题
浦发70K招行60K兴业60K华夏60K建行55K工行50K交通41K农行35.6K中信35K中行30K平安15K 11行共51.16W
只保留标金、白金卡
阅读权限100
在线时间1222 小时
我爱喵星人
在线时间1222 小时
还是用ie内核的人飘过~
小糟糟(30K)
小贱贱(30K)
小民生(50K)
工大妈(100K)
我在马路边捡到一分钱,把它交给警察叔叔手里边,叔叔拿着钱买了两包烟,我说叔叔不要脸就是不要脸……
阅读权限50
在线时间494 小时
在线时间494 小时
bg4iww 发表于
真正支持非IE内核浏览器访问的网银还是少数的,大多数银行不支持。先不说别的,Linux平台的UKEY驱动就是个问 ...
浦发这点很完美。
阅读权限80
在线时间1081 小时
在线时间1081 小时
hobboy 发表于
浦发这点很完美。
问题是我所在的小城市没有浦发一类的银行,除了五大行再就只有招商、兴业、邮政了
浦发70K招行60K兴业60K华夏60K建行55K工行50K交通41K农行35.6K中信35K中行30K平安15K 11行共51.16W
只保留标金、白金卡
特殊贡献奖
特殊贡献奖
热门信用卡中心
热门信用卡申请
信用卡问答
Powered by Discuz! X3&
我爱卡客服

我要回帖

更多关于 execcommand saveas 的文章

 

随机推荐