In javascript there's a command called
window.open( myUrl, myWindowName, myAttributes )
I was helping out a friend today and put this line of code into her script:
window.open( "www.google.com", "My Window", "height=200" );
It didn't work. I knew it was a syntax error since an alert I put right after it didn't fire.
After fiddling with this for 15 minutes, I tried it out in firefox on a hunch. Sure enough, it worked. I immediately googled "window.open not working in internet explorer" and found what I needed.
Turns out IE does not support a space in the name of a window. "My_Window" is acceptable, but "My Window" is not.
I don't even know what to say.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment