Author |
Topic |
|
nemesis
Starting Member
43 Posts |
Posted - 24 April 2001 : 15:57:26
|
Hi,
I am not sure if this post can go here but hey..
I am trying to create links on my Portal that would open new Javascript windows ie <A HREF="javascript:window.open('url','_blank','height=200,width=400')"> This works perfect EXCEPT... a window opens after you click the link, another window opens that is the right url and size. The "Previous" window displays a white page and a message [Object] and thats it. Is there a way I can do this without having a [OBJECT] window open.
All help is waaaayy appreciated.. Thanks
Nem Depression is merely Anger without enthusiasm. |
|
HuwR
Forum Admin
United Kingdom
20584 Posts |
Posted - 24 April 2001 : 16:09:19
|
try it like this
<A HREF="javascript:window.open('url','new_page','height=200,width=400')">
|
|
|
nemesis
Starting Member
43 Posts |
Posted - 24 April 2001 : 16:58:20
|
Thanks Huwr,
Same problem. It works if I use _top,_self,_parent (I guess the definition of works is it does not show [object] but it is for ob reasons not in a window. You can see what I mean by clicking on the first image on this page. http://www.mybay.co.za/Weather/satellite_images.asp
The last image "Works" but I cannot get it to the "Window" mode ie hidden menu etc..
Thanks Huwr
Nem Depression is merely Anger without Enthusiasm. http://www.mybay.co.za |
|
|
tilttek
Junior Member
Canada
333 Posts |
Posted - 25 April 2001 : 10:51:38
|
quote:
Same problem. It works if I use _top,_self,_parent (I guess the definition of works is it does not show [object] but it is for ob reasons not in a window. You can see what I mean by clicking on the first image on this page.
window.open Open a new window... The second parameter is the new name of you window you'll open. No need of _blank, _top, _self, _parent. You will create problem.
Philippe Gamache http://www.tilttek.com http://www.lapageamelkor.com |
|
|
HuwR
Forum Admin
United Kingdom
20584 Posts |
Posted - 25 April 2001 : 10:57:11
|
quote:
Thanks Huwr,
Same problem. It works if I use _top,_self,_parent (I guess the definition of works is it does not show [object] but it is for ob reasons not in a window. You can see what I mean by clicking on the first image on this page. http://www.mybay.co.za/Weather/satellite_images.asp
The last image "Works" but I cannot get it to the "Window" mode ie hidden menu etc..
Thanks Huwr
Nem Depression is merely Anger without Enthusiasm. http://www.mybay.co.za
Ok, I think the problem is you are passing an image as the url
|
|
|
nemesis
Starting Member
43 Posts |
Posted - 25 April 2001 : 16:53:20
|
Huwr I thought that was the problem..
..it aint..
The closest I could get to the answer is opening the image in a new window. But that brings all the Kak (South African for POO) of IE (Scrollbars, Menu, Ect)
Apparently Microsoft claim.. http://support.microsoft.com/support/kb/articles/Q257/3/21.ASP Bill Gates Voice.. ahemm..
"..this problem occurs because the browser is navigating to the window object returened by the Window.open file call.."
"..to resolve this problem, perform one of the following:
- Add a void (0), as illustrated here, to give a no return value: <a href="javascript:window.open('http://www.microsoft.com'); void(0)">Click here</a>
-or-
- Call your own JScript function to open a new window. This prevents the hyperlink navigation and allows you to retain a reference to the opened window. <SCRIPT>
var childWin;
function OpenUrl(url) { childWin = window.open(url); }
</SCRIPT>
<a href="javascript:OpenUrl('http://www.microsoft.com');">Click here</a><p>.."
..Yeah right Mr Microsoft, if it were that easy..
I could get neither of the above to work..
Game is back in play..
Thanks
Nem Depression is merely Anger without Enthusiasm. http://www.mybay.co.za |
|
|
|
Topic |
|