解决ff和ie脚本兼容问题_IE脚本标签问题

news/2024/7/19 16:37:18 标签: html, python, javascript, js, web
htmledit_views">
解决ff和ie脚本兼容问题

解决ff和ie脚本兼容问题

Issue: The page not displayed in IE. "View Source" shows the full source, <title> is displayed OK, but the page is not blank. White screen of death. Nothing.

问题:该页面未在IE中显示。 “查看源代码”显示完整的源代码, <title>显示为“确定”,但是页面不是空白。 白屏死机。 没有。

Cause:

原因:

<script type="text/javascript" src="some.js" />

Solution:

解:

<script type="text/javascript" src="some.js"></script>

Comments: It's probably this whole thing with the current support of XHTML. Most browsers (in their forgiveness for HTML authoring errors) interpret XHTML as HTML with some weirdly placed slashes and other noise. So for example they see <br /> as a slightly broken <br>. More about this here. In the case above probably IE needs the end </script> tag and because it cannot find it, it treats the whole HTML document as JavaScript, apparently broken. Hence the white page with OK source and OK HTML title.

注释:在XHTML的当前支持下,这可能就是整件事。 大多数浏览器(出于对HTML创作错误的宽恕)将XHTML解释为HTML,并带有一些奇怪的斜杠和其他噪点。 因此,例如,他们将<br />视为稍微损坏的<br> 。 在这里了解更多。 在上述情况下,IE可能需要end </script>标记,并且由于找不到该标记,因此将整个HTML文档视为JavaScript,显然已损坏。 因此,具有确定的源和正确HTML标题的白页。

... And while on the script tag subject, "language" is not a valid XHTML Strict attribute for <script>.

...并且在脚本标签主题上,“语言”不是<script>的有效XHTML Strict属性。

Tell your friends about this post on Facebook and Twitter

在Facebook和Twitter上告诉您的朋友有关此帖子的信息

翻译自: https://www.phpied.com/ie-script-tag-problem/

解决ff和ie脚本兼容问题


http://www.niftyadmin.cn/n/1306712.html

相关文章

qgis加载高德自定义_QGIS开发之自定义符号

昨天在程序里添加了编辑矢量图层符号的功能&#xff0c;右键LayerTree的矢量图层&#xff0c;选择“Edit Symbol”&#xff0c;便可以选择或编辑图层的渲染符号。实现方法很简单&#xff0c;首先参照http://blog.csdn.net/deirjie/article/details/50428179&#xff0c;实现自定…

firebug中的console常用的方法

firebug中的console常用的方法 1、console.log("Hello!"); --------------------显示基本信息 2、console.info("Hello!");--------------------显示一般信息 3、console.debug("Hello!");----------------显示除错信息 4、console.warn("H…

ajax调用ajax_AJAX横幅旋转

ajax调用ajaxSo heres the case: rotate ads on a website, even when the page is not reloaded. If the chances are that the visitor will spend more time on a page, it makes sense to opt-in for displaying more than one ad at one page load. Ive done this in the …

符号决定成败

今天&#xff0c;我在优化导出时&#xff0c;发现我做的页面按照日期进行查询时&#xff0c;SQL语句打印出来的日期总是初始化的日期。令人奇怪的是&#xff0c;其他参数&#xff08;地市编码等&#xff09;查询都没有问题&#xff0c;单单只有日期查询出现问题&#xff0c;真不…

mysql注入式攻击_mybatis是如何防止SQL注入的

mybatis是如何防止SQL注入的参考:1、首先看一下下面两个sql语句的区别&#xff1a;select id, username, password, rolefrom userwhere username #{username,jdbcTypeVARCHAR}and password #{password,jdbcTypeVARCHAR}select id, username, password, rolefrom userwhere u…

phpbb seo_phpBB书评

phpbb seoI was browsing Amazon today and decided to check the page of my phpBB book. There was a new (second) review by a reader, very flattering &#x1f642; Many thanks to the both reviewers if they happen to read this blog post someday! 我今天正在浏览A…

springboot项目weebapp文件夹_关于Springboot配置文件的理解

一、SpringbootSpringboot是用来简化Spring框架搭建和开发一款框架&#xff0c;可以理解为是一种Spring框架的简化版。二、如何在IDEA里面初始化Springboot主要可以分为两种方式&#xff1a;第一种直接去官网上下载&#xff1a;https://start.spring.io/。第二种是通过IDEA去官…

Java求素数时出现错误

Java求素数时出现错误 1、具体错误如下 No enclosing instance of type Prime is accessible. Must qualify the allocation with an enclosing instance of type Prime (e.g. x.new A() where x is an instance of Prime). 2、错误原因 class PrimNumber{public boolean isPri…