在严格模式下,Mozilla / Gecko / Netscape中的Javascript'history'对象不可用? [英] Javascript 'history' object unavailable in Mozilla/Gecko/Netscape in strict mode??
问题描述
大家好,
我写了这段小代码,这似乎不适用于
Mozilla 1.5。我没有在其他Gecko浏览器上尝试过,但我发现
表明Netscape 6+有同样的问题。 Internet Explorer 6
和Opera 7没有任何问题。
<!DOCTYPE html PUBLIC'' - // W3C // DTD XHTML 1.1 / / EN''
''http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd''>
< script> document .write(window.history.length);< / script>
Mozilla返回错误window.history没有属性。
广泛在互联网上搜索没有任何帮助,即使是Mozilla自己的DOM
参考文献也没有说明:
http://mozilla.org/docs/dom/domref/d...dow_ref25.html
任何人都可以帮助我,并告诉我如何使用历史对象模拟''history.back()''没有
?
谢谢,彼得
Hi all,
I''ve written this little piece of code, which doesn''t seem to work in
Mozilla 1.5. I haven''t tried it on other Gecko browsers, but I''ve found
some indication that Netscape 6+ has the same problem. Internet Explorer 6
and Opera 7 have no problems with it.
<!DOCTYPE html PUBLIC ''-//W3C//DTD XHTML 1.1//EN''
''http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd''>
<script>document.write (window.history.length);</script>
Mozilla returns the error "window.history has no properties".
Extensive searching on internet gave no help, even Mozilla''s own DOM
Reference says nothing about it:
http://mozilla.org/docs/dom/domref/d...dow_ref25.html
Can anybody help me, and tell me how to emulate ''history.back()'' without
using the history object?
Thanks, Peter
推荐答案
" rf" <毫安********** @ the.time>在消息中写道
news:z2 *************** @ news-server.bigpond.net.au ...
"rf" <ma**********@the.time> wrote in message
news:z2***************@news-server.bigpond.net.au...
彼得·布雷默 < - >在消息中写道
新闻:3f *********************** @ news.xs4all.nl ...
"Peter Bremer" <-> wrote in message
news:3f***********************@news.xs4all.nl...
大家好,
我写了这段代码,这似乎不适用于Mozilla 1.5。我没有在其他Gecko浏览器上尝试过,但我发现Netscape 6+有同样问题的一些迹象。互联网
Hi all,
I''ve written this little piece of code, which doesn''t seem to work in
Mozilla 1.5. I haven''t tried it on other Gecko browsers, but I''ve found
some indication that Netscape 6+ has the same problem. Internet
资源管理器6
Explorer 6
和Opera 7没有任何问题。
<!DOCTYPE html PUBLIC'' - // W3C // DTD XHTML 1.1 // EN''
''http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd''>
< script> document.write(window .history.length);< / script>
Mozilla返回错误window.history没有属性。
在互联网上进行广泛搜索没有任何帮助,即使是Mozilla's'自己的DOM
参考文献没有说明:
http://mozilla.org/docs/dom/domref/d...dow_ref25.html
任何人都可以帮助我,并告诉我如何效仿''history.back( )''没有
使用历史对象?
and Opera 7 have no problems with it.
<!DOCTYPE html PUBLIC ''-//W3C//DTD XHTML 1.1//EN''
''http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd''>
<script>document.write (window.history.length);</script>
Mozilla returns the error "window.history has no properties".
Extensive searching on internet gave no help, even Mozilla''s own DOM
Reference says nothing about it:
http://mozilla.org/docs/dom/domref/d...dow_ref25.html
Can anybody help me, and tell me how to emulate ''history.back()'' without
using the history object?
< p>按下您的浏览器返回按钮返回你来自的地方< / p>
干杯
理查德。
<p>Press your browsers "back" button to return to where you came from</p>
Cheers
Richard.
Hehehehe .... funnyyyyy。 .. :-)
好吧,让我改一言:任何人都可以帮助我,并告诉我如何效仿
''history.back()''使用JAVASCRIPT代码,不使用历史对象?
Hehehehe.... funnyyyyy... :-)
Okay, let me rephrase: Can anybody help me, and tell me how to emulate
''history.back()'' USING JAVASCRIPT CODE, without using the history object?
在帖子< 3f *********************** @ news.xs4all.nl>
Peter Bremer说...
In post <3f***********************@news.xs4all.nl>
Peter Bremer said...
任何人都可以帮助我,并告诉我如何效仿''history.back( )''没有
使用历史对象?
Can anybody help me, and tell me how to emulate ''history.back()'' without
using the history object?
我见过的每个浏览器都已经有能力返回到
之前的资源内置并且它的工作原理是一件好事
考虑到这个简单的小链接之后最常用的功能。
你正在尝试重新发明轮子,它最多只是方形。
你在浪费时间。
-
brucie a。布莱克福德。 30 / July / 2003 10:51:34 pm kilo。
http:// loser。 brucies.com/
" Vjekoslav Begovic" < VJ ******* @ inet.hr>在消息中写道
news:bg ********** @ sunce.iskon.hr ...
"Vjekoslav Begovic" <vj*******@inet.hr> wrote in message
news:bg**********@sunce.iskon.hr...
也许使用document.location和document.refferer属性?
Perhaps using document.location and document.refferer properties?
抱歉,window.location和document.referer当然。
Sorry, window.location and document.referer, of course.
这篇关于在严格模式下,Mozilla / Gecko / Netscape中的Javascript'history'对象不可用?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!