Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

IE7 and parent.location not working?

 
Marcin O'Sullivan
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,



In a script used by svg, I have a like like the following to go to a new web page:







This works fine in IE6. However, it has no effect in ie7 (not even a error message, or security message) It just does nothing.

I have noised when i do:









values displayed by alert are not the same!!! parent.parent.location was not overwritten.



(I tried window.location=, window.assign(newUrl), parent.location.href, parent.location= .... none of it works, and I don't get an error message)

Project uses Frames.



Is this expected behavior in ie7? Is this a security thing? Where is there information on this?



Thanks,

MR
 
Roger F. Gay
Ranch Hand
Posts: 408
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I don't know where there might be documentation on the problem, but I got document.location= and document.location.href= to work fine in IE7. Now that you mention it though, I have had unexpected problems with parent.... Perhaps I will post that problem separately. You might want to try window.location.replace(URL) or even document.location.replace(URL). (I haven't.)
[ April 23, 2007: Message edited by: Roger F. Gay ]
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 64824
86
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"camer",

There aren't many rules that you need to worry about here on the Ranch, but one that we take very seriously regards the use of proper names. Please take a look at the JavaRanch Naming Policy and adjust your display name to match it.

In particular, your display name must be a first and a last name separated by a space character, and must not be obviously fictitious.

Thanks!
bear
JavaRanch Sheriff
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic