PDA

View Full Version : Pass detail to parent window


jayp
01-07-2003, 08:19 PM
I have a web page that spawns a child window when a link is clicked. This child windows contains a table representing a calendar month. Each day of the month acts as a link e.g. <a href="whatever.asp?theDate=5/5/2003">5</a>
I want the user to be able to select a day (by clicking the link) this will then close the child window and return (in this example) 5/5/2003 to a form field on the parent window. I can't refresh the parent window as I will lose form data on there so need a client-side solution.... please?

Jay

jayp
01-07-2003, 08:24 PM
Hi people,
Please ignore my post as I found the answer in a prior thread.

Jay

scroots
01-07-2003, 08:25 PM
you might want to check out my script it is not quite an exact solution but it might work for you.

<script language="javascript">
<!--
function pp(x){
var f
f = 'pic.asp?ID=';
f += x
window.open("f", "TITLE", "toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=0,resizeable=0,width=800,height=600");
}
// done hiding -->
</SCRIPT>
and then for each link/image
<a href="#" onClick="pp('a')"><img border="0" src="peeps.gif" width="42" height="43"></a>


scroots

ez4ne12c
01-07-2003, 10:22 PM
Have you seen this
http://www.wsabstract.com/script/script2/timestamp.shtml

ez

jayp
01-07-2003, 10:31 PM
Thanks for that, I've saved the script for future use.

Jay