Meaningless Drivel is fun!
The moose likes HTML, CSS and JavaScript and the fly likes Javascript child window Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "Javascript child window" Watch "Javascript child window" New topic

Javascript child window

Richard Ellison
Ranch Hand

Joined: Jun 04, 2008
Posts: 51
I have a javascript related question.Following is the function of the JSP:
Each row in the JSP has a text field and a button.On clicking the button,a pop-up window is opened.This pop-up window
presents the user with a list.The user may choose one by clicking on the appropriate radio button.The text box
in the parent window should be populated with the row selected.My problem is,the child window does not know the row on which
the button(to show the pop-up) was pressed.

I tried to pass the rownumber as a parameter in the event of the parent window.But the child window
was not able to read this parameter-says that it is undefined.Is there a way for the row number of the parent window to be passed
to the child window so that upon selection,the correct text field in the parent window is populated?

I look forward to hearing from you.

Bear Bibeault
Author and ninkuma

Joined: Jan 10, 2002
Posts: 63858

Rather than doing this in a popup window, why not just use a positioned div to float a faux dialog on top of the rest of the controls? That way, you don't have to deal with more than one window.

Or, within the child window, the parent is available via the predefined parent variable.

If it's the request parameter you are having trouble with, you're going to have to do a much better job explaining what the issue is.

[Asking smart questions] [About Bear] [Books by Bear]
I agree. Here's the link:
subject: Javascript child window
It's not a secret anymore!