简体   繁体   English

单击按钮在IE9中不起作用,但没有错误消息(在Chrome中有效)

[英]Click on button doesn't work in IE9 but no error message (it works in chrome)

I want to try this applet. 我想试试这个小程序。

when clicking on button continue in IE it doesn't work whereas in chrome it does. 当单击按钮继续在IE中无法使用,而在chrome则可以。

Why? 为什么? There's no error message. 没有错误信息。

In your JavaScript console (in IE9), you are getting an error. 在您的JavaScript控制台(在IE9中)中,出现错误。

Object doesn't support property or method 'trim' 对象不支持属性或方法“修剪”

IE < 9 doesn't support String.prototype.trim . IE <9不支持String.prototype.trim You page is running in "Quirks mode" which means it's running like it's in an old version of IE. 您的页面以“ Quirks模式”运行,这意味着它的运行方式与旧版本的IE相同。

Try to force IE to run the page in the correct mode by adding this to the <head> : 尝试通过将IE添加到<head>来强制IE以正确的模式运行页面:

<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">

You should also add a doctype to your page. 您还应该在页面上添加一个文档类型 Here's the HTML5 one (put this at the top of the page (before <html> ): 这是HTML5(将其放在页面顶部(在<html>之前):

<!DOCTYPE html>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Selenium chrome 驱动程序 (Java) click() 登录按钮不能以编程方式工作,但可以手动工作 - Selenium chrome driver (Java) click() login button doesn't work programmatically but works manually jQuery在FF或IE中不起作用,但在Chrome中可以正常工作 - jQuery doesn't work in FF or IE but works fine in Chrome 在IE11中获取错误“对象不支持属性或方法&#39;attachEvent&#39;”但在IE8,IE9,IE10中工作 - Getting Error “Object doesn't support property or method 'attachEvent'” in IE11 but work in IE8, IE9, IE10 在第二个布局上单击按钮不起作用 - Button click on second layout doesn't work 使用Htmlunit,不起作用按钮click(); - use Htmlunit, doesn't work button click(); 点击按钮的上半部分 - 不起作用? - Click on the top half of a button - doesn't work? 在兼容性视图中,部分更新不适用于primefaces 4.0和IE9 - Partial update doesn't work with primefaces 4.0 and IE9 in compatibility view JDBCRealm不起作用,但没有错误消息 - JDBCRealm doesn't work but there is no error message Spring Boot错误消息不起作用 - Spring Boot error message doesn't work 对象不支持此属性或方法 -- 在 IE9 中调用 Applet - Object doesn't support this property or method -- Calling an Applet in IE9
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM