473,324 Members | 2,254 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,324 software developers and data experts.

tough question 2

how to do the follows in IE:
there's page A with element a
pop a new page B from script in A
and append element a into B
after closing page B
put element a back into A

'IE' solution only

Jun 27 '08 #1
12 1456
VK
On Apr 14, 12:46 am, Mr Shore <shore.cl...@gmail.comwrote:
how to do the follows in IE:
there's page A with element a
pop a new page B from script in A
and append element a into B
after closing page B
put element a back into A

'IE' solution only
You should use JScript or VBScript, I guess. As "IE only solution" you
may check my advise at microsoft.public.scripting.jscript but I'm
pretty sure that they will come to the same conclusion.

Post or link your best attempt you have made so far and we may try to
come together to some cross-browser solution.
Jun 27 '08 #2
On Apr 14, 4:58 am, VK <schools_r...@yahoo.comwrote:
On Apr 14, 12:46 am, Mr Shore <shore.cl...@gmail.comwrote:
how to do the follows in IE:
there's page A with element a
pop a new page B from script in A
and append element a into B
after closing page B
put element a back into A
'IE' solution only

You should use JScript or VBScript, I guess. As "IE only solution" you
may check my advise at microsoft.public.scripting.jscript but I'm
pretty sure that they will come to the same conclusion.

Post or link your best attempt you have made so far and we may try to
come together to some cross-browser solution.
ok,to declare it more clearly
the parent window:
<body>
<script>
function OpenChild()
{
var childWin = window.open("t.html");
}

</script>
<input type="button" onclick="OpenChild()"/>
<input type="button" id="try" onclick="f();"/>
</body>
the son window:
<html>
<body onbeforeunload="g();" onload="X();">

<script>

function X()
{

document.body.appendChild(window.opener.document.g etElementById('try'));
}
function g()
{

window.opener.document.body.appendChild(document.g etElementById('try'));
}
</script>
</body>
</html>
passed in ff,but failed in IE
Jun 27 '08 #3
document.body.appendChild(window.opener.document.g etElementById('try'));
window.opener.document.body.appendChild(document.g etElementById('try'));
appending elements from different documents is not possible on IE (im
99% sure), you have to create the elements
on their corresponding document, probably would be better if you use
innerHTML
Jun 27 '08 #4
Lee
Mr Shore said:

You might also want to consider the fact that many people
will ignore messages with useless subject lines like
"tough question".
Use the subject line to give a clue about what sort of
question you're asking.
--

Jun 27 '08 #5
On Apr 14, 10:10 am, RoLo <roloswo...@gmail.comwrote:
document.body.appendChild(window.opener.document.g etElementById('try'));
window.opener.document.body.appendChild(document.g etElementById('try'));

appending elements from different documents is not possible on IE (im
99% sure), you have to create the elements
on their corresponding document, probably would be better if you use
innerHTML
have you ever used this online im?
http://www.meebo.com/
the chat window can be poped up both in ff and IE
Jun 27 '08 #6
On Apr 14, 11:37 am, Lee <REM0VElbspamt...@cox.netwrote:
Mr Shore said:

You might also want to consider the fact that many people
will ignore messages with useless subject lines like
"tough question".
Use the subject line to give a clue about what sort of
question you're asking.

--
ok
Jun 27 '08 #7
Mr Shore <sh*********@gmail.comwrites:
On Apr 14, 10:10 am, RoLo <roloswo...@gmail.comwrote:
document.body.appendChild(window.opener.document.g etElementById('try'));
window.opener.document.body.appendChild(document.g etElementById('try'));

appending elements from different documents is not possible on IE (im
99% sure), you have to create the elements
on their corresponding document, probably would be better if you use
innerHTML

have you ever used this online im?
http://www.meebo.com/
the chat window can be poped up both in ff and IE
What's that got to do with anything? Read RoLo's text again. By the way,
the quoted code also won't work on Opera; again - you shouldn't move
elements from one document to another.

--
Joost Diepenmaat | blog: http://joost.zeekat.nl/ | work: http://zeekat.nl/
Jun 27 '08 #8
On Apr 13, 4:46*pm, Mr Shore <shore.cl...@gmail.comwrote:
how to do the follows in IE:
there's page A with element a
pop a new page B from script in A
and append element a into B
after closing page B
put element a back into A

'IE' solution only
As stated, appending elements from one page to another is a bad idea.
Just return a value from page B and construct a new element in page
A. Not a big deal.

Bob
Jun 27 '08 #9
On Apr 14, 10:11 pm, beegee <bgul...@gmail.comwrote:
On Apr 13, 4:46 pm, Mr Shore <shore.cl...@gmail.comwrote:
how to do the follows in IE:
there's page A with element a
pop a new page B from script in A
and append element a into B
after closing page B
put element a back into A
'IE' solution only

As stated, appending elements from one page to another is a bad idea.
Just return a value from page B and construct a new element in page
A. Not a big deal.

Bob
could you provide a instance?
elements with listeners are quite troublesome to handle i think
Jun 27 '08 #10
On Apr 14, 7:32 pm, Joost Diepenmaat <jo...@zeekat.nlwrote:
Mr Shore <shore.cl...@gmail.comwrites:
On Apr 14, 10:10 am, RoLo <roloswo...@gmail.comwrote:
document.body.appendChild(window.opener.document.g etElementById('try'));
window.opener.document.body.appendChild(document.g etElementById('try'));
appending elements from different documents is not possible on IE (im
99% sure), you have to create the elements
on their corresponding document, probably would be better if you use
innerHTML
have you ever used this online im?
http://www.meebo.com/
the chat window can be poped up both in ff and IE

What's that got to do with anything? Read RoLo's text again. By the way,
the quoted code also won't work on Opera; again - you shouldn't move
elements from one document to another.

--
Joost Diepenmaat | blog:http://joost.zeekat.nl/| work:http://zeekat.nl/
have you tried its im chat functionality?
it can pop out from parent window and return to the parent windows
when the popping out window is closed,which is the same with my case
in principle
Jun 27 '08 #11
Mr Shore <sh*********@gmail.comwrites:
have you tried its im chat functionality?
No.
it can pop out from parent window and return to the parent windows
when the popping out window is closed,which is the same with my case
in principle
But that's unrelated to the problem. You seem to be misreading the
(correct) statement "you can't reliably move nodes / elements from one
document to the other" as "you can't communicate between documents".

IOW, the exactly problem is that:

someElement.appendChild(otherElement);

Is *NOT* guaranteed to work when otherElement is not created by and/or
removed from the same root document that someElement was created by
and/or removed from.
--
Joost Diepenmaat | blog: http://joost.zeekat.nl/ | work: http://zeekat.nl/
Jun 27 '08 #12
On Apr 15, 3:25 am, Joost Diepenmaat <jo...@zeekat.nlwrote:
Mr Shore <shore.cl...@gmail.comwrites:
have you tried its im chat functionality?

No.
it can pop out from parent window and return to the parent windows
when the popping out window is closed,which is the same with my case
in principle

But that's unrelated to the problem. You seem to be misreading the
(correct) statement "you can't reliably move nodes / elements from one
document to the other" as "you can't communicate between documents".

IOW, the exactly problem is that:

someElement.appendChild(otherElement);

Is *NOT* guaranteed to work when otherElement is not created by and/or
removed from the same root document that someElement was created by
and/or removed from.

--
Joost Diepenmaat | blog:http://joost.zeekat.nl/| work:http://zeekat.nl/
i think i can have a try to find it work both in IE and ff about which
i'm curious
Jun 27 '08 #13

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: Christine Long | last post by:
Webmasters: Colance specialise in connecting your ideas with Freelance Professionals to produce your project. Programmers: Providing your Service is made easy through Colance. It is free to sign up...
0
by: Aaron Williams | last post by:
Webmasters: Colance specialise in connecting your ideas with Freelance Professionals to produce your project. Programmers: Providing your Service is made easy through Colance. It is free to sign up...
3
by: eric rudolph | last post by:
1. I'm designing a PHP-based page that has a lot of design stuff in it. It's very tough to mix the HTML and PHP and have it be readable. The site isn't overall so complicated, there's just a lot of...
5
by: Abyss | last post by:
My view. anyone that doesn't like it tough, click off and stop reading it. I have spent the last 45 minutes reading through all the posts, and I believe that you have all missed the mark of...
6
by: Kennedy_f | last post by:
I did better in terms of score on this one than 291, but I found it much harder. Wordings of questions are difficult like the rest, but the DNS and CA scenarios were very tough to figure out. Take...
28
by: Arial | last post by:
My SQL string is kind of wierd one. In my application, I need to select things from an unknown name table. But I know the table name before the SQL command is executed. For instance, Dim...
9
by: denis | last post by:
Hi there, I got a tough interview questions lately, and I would like to hear your opinion: An array of N chars is given Write an efficient algorithm to find all the repeating substring with a ...
1
by: Cowboy \(Gregory A. Beamer\) | last post by:
If you have a tough time getting your head around Lambda Expressions, see if this blog entry helps: http://tinyurl.com/4yeckd I would gladly welcome comments, critiques and questions, as I am...
4
by: Jim Rutledge | last post by:
ok ok , anyone know anything on this tough question? How do you determine the length in seconds that a midi file is , or any audio file for that matter ?
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Shællîpôpï 09 | last post by:
If u are using a keypad phone, how do u turn on JavaScript, to access features like WhatsApp, Facebook, Instagram....
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.