Page 1 of 1

[SOLVED] new window

Posted: Tue Mar 30, 2004 1:33 pm
by magicrobotmonkey
Here's my deal. I have a form that the user goes through, fills out, and submits. On the submit page, I have three links to php files which recreate various versions of the form. These open in a new window and everything works fine. Now, I need to email one of the PDF's which has been created by a php. So I have javascript open a new window onLoad which runs the same script as the one that generates the pdf, except it emails it instead. (I have to do a new window becuase fpdf generates "HEaders already sent" errors even if you are not publishing to the page!). But this new window, instead of running the script, tries to make me download it. The php file. I can't download it, because it cant find it, but it is still weird. I guess there must be a difference apache can tell between a clicked on link and a forced-to link. But anyways, any idea how I can make this go away? Or any way I can make PHP open a new window?

Posted: Tue Mar 30, 2004 1:42 pm
by magicrobotmonkey
Uhh never mind, I just updated my version of FPDF and now I don't need the new window anymore!

Re: new window

Posted: Tue Mar 30, 2004 1:45 pm
by ol4pr0
magicrobotmonkey wrote:Now, I need to email one of the PDF's which has been created by a php. So I have javascript open a new window onLoad which runs the same script as the one that generates the pdf, except it emails it instead.
Untill there i understand the whole story, however than
magicrobotmonkey wrote:But this new window, instead of running the script, tries to make me download it.
Now you have lost me ..


What are you trying to run in the new window ?

Dont think php can do the open in new window, that is javascript for as far as i know