----- Original Message ----- From: "Emma Jane Hogbin" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, June 09, 2003 2:32 PM Subject: Re: [PHP] sessions, IE and pop-up windows
> On Mon, Jun 09, 2003 at 02:27:50PM -0600, Kevin Stone wrote: > > I'll bet you're using an onLoad command to launch the popup aren't you. Use > > Output Buffering to keep stdout from flushing before the parent script dies. > > If my assumption about onLoad is correct then that'll solve your problem. > > Um not "onload" the link looks like this: > <a onclick='openEdit("add=event&cellid=10"); return false;' > onkeypress='openEdit("add=event&cellid=10"); return > false;'href='edit.php?add=event&cellid=10'>Add an event</a> > > and the javascript looks like this: > // its goal is to EDIT any type of content in a pop-up window > function openEdit(params) { > var url = "editsmall.php?"+params; > var ewin = window.open(url, "ewin", "width=500,height=300,toolbar=0,resizable=1,scrollbars=1"); > ewin.focus(); > } Blows that theory away. :-) I still believe what's happening is the edit script is being executed before the parent script has died. Are you doing some kind of looping background process or something that's keeping the parent script from exiting? As far as I know you cannot have two instances of the same session running simultaneously. The way I understand sessions it should be systemically impossible to do so unless there's some kind of flock'ing option for session files that I don't know of. Of course that doesn't mean PHP won't let you try. You need to avoid this situation by -> killing that parent script<- before the edit script is launched. You can ensure this with output buffering as I suggested before. Becuase you're controlling the output there won't be a button to press until the parent script has died. ob_start(); //script here// ob_end_flush(); HTH, Kevin -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php