944,116 Members | Top Members by Rank

Ad:
You are currently viewing page 1 of this multi-page discussion thread
Jul 19th, 2007
0

Open.window popup

Expand Post »
hi
i need to open a new window using open.window to control some parameters, like window size, bars, scrollbars... the problem is that this way the brower blocks the window like if it was a popup...
is there any way to solve this?

if there is any other way to control the window parameters, like while its loading, feel free to post where, it would be much more usefull to me

thanks
Similar Threads
Reputation Points: 10
Solved Threads: 0
Light Poster
DeOiD is offline Offline
30 posts
since Apr 2007
Jul 19th, 2007
0

Re: Open.window popup

As long as you don't call it on a page load or something similar the pop up will open just fine. Basically, it has to be opened based on a user action (i.e. they click on a link). So it is not the code that is the issue, it is how the pop up is called.
Moderator
Reputation Points: 161
Solved Threads: 38
He's No Good To Me Dead
stymiee is offline Offline
1,422 posts
since May 2006
Jul 19th, 2007
0

Re: Open.window popup

> if there is any other way to control the window parameters, like while its loading, feel free to post
Set the focus to the parent window, so that the newly opened window can load in the background and the user can browse the original page.

If you still don't get it, let me know.
Last edited by ~s.o.s~; Jul 19th, 2007 at 1:48 pm.
Super Moderator
Featured Poster
Reputation Points: 3241
Solved Threads: 719
Failure as a human
~s.o.s~ is offline Offline
8,873 posts
since Jun 2006
Jul 19th, 2007
0

Re: Open.window popup

sorry, don't get it...

i'm using a normal page to open another page after 3 seconds, but only because i don't know any other way to control the window.

window.open("fgo.aspx","new ",
"toolbar=no,directories=no,status=no,titlebar=no,
menubar=no,scrollbars=no,resizable=no,width=800,
height=600,top=0,left=0")


what i meant was that if there is a way to control a window without using the first one with the javascript code above, it would be great...

thanks
Reputation Points: 10
Solved Threads: 0
Light Poster
DeOiD is offline Offline
30 posts
since Apr 2007
Jul 19th, 2007
0

Re: Open.window popup

What you are trying to do is exactly what popup blockers try to block.
Moderator
Reputation Points: 161
Solved Threads: 38
He's No Good To Me Dead
stymiee is offline Offline
1,422 posts
since May 2006
Jul 20th, 2007
0

Re: Open.window popup

i know, but that's what my boss wants...

it's amazing, so many new web technologies and theres no way to control the window parameters...
Reputation Points: 10
Solved Threads: 0
Light Poster
DeOiD is offline Offline
30 posts
since Apr 2007
Jul 20th, 2007
0

Re: Open.window popup

I don't properly understand what you are trying to do here, but as far as I can make out, I guess you want to create a new window and allow it to load in the background while the user keeps on working with the original window.

JavaScript / DHTML / AJAX Syntax (Toggle Plain Text)
  1. // ee.html
  2. <html>
  3. <head>
  4. <script>
  5. function doSome()
  6. {
  7. var wnd = window.open("dd.html");
  8. if(!wnd.opener)
  9. wnd.opener = self;
  10. }
  11. </script>
  12. </head>
  13. <body>
  14. <input type="button" value="Open Window" id="btn" onclick="doSome();" />
  15. </body>
  16. </html>
  17.  
  18. // dd.html
  19. <html>
  20. <head>
  21. <script>
  22. function shiftFocus()
  23. {
  24. opener.focus();
  25. }
  26. </script>
  27. </head>
  28. <body onload="shiftFocus();">
  29. <div>This really is something.</div>
  30. </body>
  31. </html>

If not, then please specify which parameters you want to control.
Super Moderator
Featured Poster
Reputation Points: 3241
Solved Threads: 719
Failure as a human
~s.o.s~ is offline Offline
8,873 posts
since Jun 2006
Jul 20th, 2007
0

Re: Open.window popup

Wow, I have the power to block your boss! I will use it. BLOCK!!!!

The trick is to provide a button the USER clicks to open the window.

Any window which opens without the USER deciding to open it by clicking something is a popup ad.
Last edited by MidiMagic; Jul 20th, 2007 at 6:41 pm.
Reputation Points: 730
Solved Threads: 181
Nearly a Senior Poster
MidiMagic is offline Offline
3,314 posts
since Jan 2007
Jul 21st, 2007
0

Re: Open.window popup

ok, my english limitations are creating some confusion here...

i'll try to explain what i need. my boss wants that when someone goes to (for example) www.xpto.com, the window appears without scrollbars, statusbars, toolbars... basically just the window frame and nothing more... the problem is that it appears that the only way to control these parameters is to open a new window using:

window.open("fgo.aspx","new","toolbar=no,directories=no,
status=no,titlebar=no,menubar=no,scrollbars=no,resizable=no,width=800,
height=600,top=0,left=0")


but this isn't what i want. if possible, i want to create this kind of window without using two pages, just one (fgo.aspx in this case)...

hope it helps understanding what i need.... and thanks for your help
Reputation Points: 10
Solved Threads: 0
Light Poster
DeOiD is offline Offline
30 posts
since Apr 2007
Jul 21st, 2007
0

Re: Open.window popup

AFAIK, no, you can't control the properties of something you don't create. Security reasons. The user is no sucker to come to your site only to find out his browser bare essentials have been stripped by some crazy developer...
Super Moderator
Featured Poster
Reputation Points: 3241
Solved Threads: 719
Failure as a human
~s.o.s~ is offline Offline
8,873 posts
since Jun 2006

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in JavaScript / DHTML / AJAX Forum Timeline: Javascript MP3 Player
Next Thread in JavaScript / DHTML / AJAX Forum Timeline: help me





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC