944,221 Members | Top Members by Rank

Ad:
You are currently viewing page 1 of this multi-page discussion thread
Sep 18th, 2006
0

Pop-up window overlapping issues

Expand Post »
Hello,

Is there a way to change the target name of a pop-up window?

If you check out my site you will see the issue I am having. What happens is when you click on "Open Chat Window" and then click on "Detach Jukebox" they populate in the same pop-up. So you can't have both windows open at the same time.

If I could change the name of the pop-up's target to "_chat" or "_jukebox" instead of "_blank" perhaps I could have both pop-ups open.

The site is http://www.stateofhumanity.org - check it out and you will see the issue.

Let me know if you know what I can do about this issue.
Reputation Points: 10
Solved Threads: 0
Newbie Poster
odinwright is offline Offline
12 posts
since Sep 2006
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

That's pretty much how you do it...except without the leading underscore.

target="chat" and target="jukebox"
Team Colleague
Reputation Points: 92
Solved Threads: 21
Posting Pro in Training
FC Jamison is offline Offline
436 posts
since Jun 2004
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

How do I identify the pop up as "chat" What code would I place in the html document?

Odin
Reputation Points: 10
Solved Threads: 0
Newbie Poster
odinwright is offline Offline
12 posts
since Sep 2006
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

[html]
<a href="linked.html" target="newwin" >link</a>
[/html]

or
window.open(URL, name [, features])
[html]
<a href="javascript: window.open('http://whatever.com', 'tinyWindow', 'toolbar,width=150,height=100')">new window</a>
[/html]
Team Colleague
Reputation Points: 92
Solved Threads: 21
Posting Pro in Training
FC Jamison is offline Offline
436 posts
since Jun 2004
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

Ok so far it works. Except the window that has the link also goes to another page and says "[object Window]" What can I do?

As you can tell I am not a coder.

Thanks for all the support.

Odin
Reputation Points: 10
Solved Threads: 0
Newbie Poster
odinwright is offline Offline
12 posts
since Sep 2006
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

show me the code you are using
Team Colleague
Reputation Points: 92
Solved Threads: 21
Posting Pro in Training
FC Jamison is offline Offline
436 posts
since Jun 2004
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

Click to Expand / Collapse  Quote originally posted by FC Jamison ...
show me the code you are using
<a href="javascript: window.open('http://www.stateofhumanity.org/chatwindow.html', 'tinyWindow', 'toolbar,width=500,height=500, status=no, scrollbars=no, menubar=no, resizeable=yes')">Open a Chat Window</a>
Reputation Points: 10
Solved Threads: 0
Newbie Poster
odinwright is offline Offline
12 posts
since Sep 2006
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

try this

javascript
HTML and CSS Syntax (Toggle Plain Text)
  1. <script type="text/javascript">
  2. function popUp(URL) {
  3. day = new Date();
  4. id = day.getTime();
  5.  
  6. eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=1,left=125,top=100,width=500,height=500');");
  7. }
  8. </script>

html
[html]
<a href="javascript:popUp('http://www.stateofhumanity.org/chatwindow.html')">popup window</a>
[/html]

p.s. no need to add window names...and put the script in the head section.
Last edited by FC Jamison; Sep 18th, 2006 at 10:56 pm.
Team Colleague
Reputation Points: 92
Solved Threads: 21
Posting Pro in Training
FC Jamison is offline Offline
436 posts
since Jun 2004
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

Click to Expand / Collapse  Quote originally posted by FC Jamison ...
try this

javascript
HTML and CSS Syntax (Toggle Plain Text)
  1. <script type="text/javascript">
  2. function popUp(URL) {
  3. day = new Date();
  4. id = day.getTime();
  5.  
  6. eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=1,left=125,top=100,width=500,height=500');");
  7. }
  8. </script>

html
[html]
<a href="javascript:popUp('http://www.stateofhumanity.org/chatwindow.html')">popup window</a>
[/html]

p.s. no need to add window names...and put the script in the head section.
Hmmm. I am going have to give this a more indepth look. The Html didn't work. And I am not familiar enough with Javascript code to implement it.:cry:

But I will continue to work at it.:cheesy:

Odin
Reputation Points: 10
Solved Threads: 0
Newbie Poster
odinwright is offline Offline
12 posts
since Sep 2006
Sep 18th, 2006
0

Re: Pop-up window overlapping issues

Here is a test page.

[html]
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Untitled Document</title>
<script type="text/javascript">
function popUp(URL) {
day = new Date();
id = day.getTime();

eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,menubar=0,resizable=0,left=125,top=100,width=150,height=150');");
}
</script>
</head>

<body>
<p><a href="javascript:popUp('http://www.stateofhumanity.org/chatwindow.html')">popup window</a>
</body>
</html>
[/html]
Last edited by FC Jamison; Sep 18th, 2006 at 11:05 pm.
Team Colleague
Reputation Points: 92
Solved Threads: 21
Posting Pro in Training
FC Jamison is offline Offline
436 posts
since Jun 2004

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 HTML and CSS Forum Timeline: Comments page
Next Thread in HTML and CSS Forum Timeline: Please help.





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


Follow us on Twitter


© 2011 DaniWeb® LLC