Page 1 of 1

Insert Address from Popup window

Posted: Wed Mar 25, 2009 9:02 am
by loonyew
Hi,

I have tried to search on the web for few days.....can't get to something like this

i have a page which have a textbox letting user key in email addresses and there is a link beside the box which will popup another small window with addresses in the database.

I have problem putting the selected email address values back to the textbox after the user clicked Ok button.

anyone has any idea?

TQ

Re: Insert Address from Popup window

Posted: Wed Mar 25, 2009 12:45 pm
by pickle
This would be Javascript, which is in the Client Side forum.

Thread moved.

Re: Insert Address from Popup window

Posted: Wed Mar 25, 2009 12:47 pm
by pickle
In Javascript, you can refer to the window.parent as a document, so I think you can do:

Code: Select all

window.parent.getElementById('id-of-field-that-holds-email-address').value = 'new-email-address';

Re: Insert Address from Popup window

Posted: Wed Apr 01, 2009 1:33 am
by loonyew
pickle wrote:In Javascript, you can refer to the window.parent as a document, so I think you can do:

Code: Select all

window.parent.getElementById('id-of-field-that-holds-email-address').value = 'new-email-address';

ohh....Thanks for the info....will try it out....