473,805 Members | 2,017 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How To: Popup Website A from Website B?

svd
Hi all,

First off, I'm developing in VB.NET 2003.

I would like to have a button on Company A's web page display Company B's
web page in a popup window. It needs to pass a serialzed class object to the
popup web page, which can be picked up in its pageload() hander. Further,
closing the popup should return a serialized class object. I'm fine with the
serialization part, just confused over the popup and passing data part.

I think this can only be accomlished using javascript and a hidden field on
each web page. I tried a number of examples, but could never get any of them
to run properly.

Any help would be greatly appreaciated.

Thanks,

Steve
Jan 13 '07 #1
3 1227
I posted the skeleton of a solution to this at
http://groups-beta.google.com/group/...61483629a4dca5

Let me know if that's any help to you. Alternatively, let me know if it
_isn't_. I was doing exactly the same thing: sending initialisation
objects to a child window, performing work from user input, then
sending js objects back to the parent.
svd wrote:
Hi all,

First off, I'm developing in VB.NET 2003.

I would like to have a button on Company A's web page display Company B's
web page in a popup window. It needs to pass a serialzed class object to the
popup web page, which can be picked up in its pageload() hander. Further,
closing the popup should return a serialized class object. I'm fine with the
serialization part, just confused over the popup and passing data part.

I think this can only be accomlished using javascript and a hidden field on
each web page. I tried a number of examples, but could never get any of them
to run properly.

Any help would be greatly appreaciated.

Thanks,

Steve
Jan 13 '07 #2
moo
Totally lost.... A cleaner example would be helpful.
Steve
Jan 14 '07 #3
Okay, an example with no fluff. The extra bits in the other example are
there to allow your two pages to vary independently of one another. I
had the situation where I had to open several windows from the first
page, and used different callback functions for those windows.

Company A:
<html>
<head>
<script type="text/javascript">
var serializedObjec t = {Foo:"Foo", Bar:"Bar"};
var myChild;

function getInitializati onObject(){ return serializedObjec t; }

function receiveObject(d ata) {alert("receive d :"+data);}

function openWindow(){my Child = window.open("co mpanyB.htm");}
</script>
</head>

<body>
<input type="button" value="Talk to Company B" onclick="openWi ndow()"
/>
</body>
</html>

----------------

Company B:

<html>
<head>
<script type="text/javascript">

function sendValue()
{
var result = {result:
document.getEle mentById("sende rBox1").value};
this.opener.rec eiveObject(resu lt);
}

function Handshake()
{
var initObject = this.opener.get InitializationO bject();
alert("received :"+initObjec t);
}
</script>
</head>
<body onload="Handsha ke()">

<input type="text" id="senderBox1 " />
<input type="button" onclick="sendVa lue()" value="send value" />
</body>
</html>

Jan 14 '07 #4

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

Similar topics

4
10492
by: Davey | last post by:
I have a website which has a popup window (this only opens when the user chooses to open it). In the popup window I have a <select> control which lists a selection of "classes". Each class has a description and a class_id (stored in the value attribute of each option). The user will then select a class from the drop-down list. What I want to do is have a control in the parent browser window which can store the class_id and the...
4
22216
by: Davey | last post by:
I have a website which has a popup window (this only opens when the user chooses to open it). In the popup window I have a <select> control which lists a selection of "classes". Each class has a description and a class_id (stored in the value attribute of each option). The user will then select a class from the drop-down list. What I want to do is have a control in the parent browser window which can store the class_id and the...
11
7359
by: Alex.Svetos | last post by:
Hello, I'm trying to get a popup to keep focus when it is re-clicked. The script below is supposed to produce this exact behaviour, however it doesn't work, at least on firefox 1.0.7 and moz 1.7.12 (linux kubuntu). It does work with konqueror. It seems to work with firefox on windows but not with IE (not completly sure though).
2
1804
by: =?Utf-8?B?U3VyZXNoIFJlZGR5?= | last post by:
I am getting a strange problem with IE7 tabs. The web application I am working (developed in ASP.Net, .Net 2.0), will show a popup message with the count down timer 2 minutes before session time out. The count down timer on popup will start with 120 and will be count down to 0 and if the user doesn't click on the Continue button (which is on popup), application logs out and the web page will be shown with login page. If the user clicks...
0
9596
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10604
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10356
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10103
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7644
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5676
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4316
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3839
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
3
3006
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.