[FX.php List] Problem creating mPDF file
James Dcunha
jdcunha at supportgroup.com
Wed Dec 26 12:37:41 MST 2012
Hi Bob,
$mpdf->Output('doc.pdf','F'); means that it is trying to create the file in
the same directory as where the script is being executed. What is the
permissions set for php scripts to create files? For test purpose try to
set Read/Write permissions for everyone and then run the script.
Regards
James
On Wed, Dec 26, 2012 at 1:42 PM, Bob Patin <bob at patin.com> wrote:
> Hey Chris,
>
> Well, it's not that, I don't think; I'm not really clear on *where* the
> PDF is temporarily written, but I get the impression that it's not on the
> web server--but I'm not sure about that.
>
> The thing is, if it *is* writing it to the web server, I don't know
> *where* on the web server, otherwise I could make sure WRITE permissions
> were assigned to that directory.
>
> argh... :)
>
> Works great on other sites I've done, just not this one... different web
> server though.
>
> Best,
>
> Bob Patin
> Longterm Solutions LLC
> bob at longtermsolutions.com
> 615-333-6858
> http://www.longtermsolutions.com
> FileMaker 9, 10 & 11 Certified Developer
> Member of FileMaker Business Alliance and FileMaker TechNet
> --
> Twitter: bobpatin
> Google+: http://www.longtermsolutions.com/plus
> AIM: longterm1954
> iChat: bobpatin
> --
> Expert FileMaker Consulting
> FileMaker Hosting for all versions of FileMaker
>
> On Dec 26, 2012, at 12:23 PM, Chris Hansen <chris at iViking.org> wrote:
>
> > Bob,
> >
> > It sounds to me like there's some problem writing the file (even if
> you're sending an email, it's putting the file somewhere for use when it's
> needed...) Any idea what directory it's using for that storage? Is it
> perhaps trying to store the file in a non-existant directory, or one for
> which the web user has insufficient permissions? Any more details in the
> apache error log?
> >
> > Best,
> >
> > --Chris
> >
> > On Dec 26, 2012, at 11:05 AM, Bob Patin wrote:
> >
> >> I'm having a problem creating a PDF using mPDF; here's what happens:
> >>
> >> 1. If I create the PDF to the browser
> >>
> >> $mpdf->Output();
> >>
> >> it works fine.
> >>
> >> 2. If I try to create the PDF using a filename, so that I can attach
> and email it
> >>
> >> $mpdf->Output('doc.pdf','F');
> >>
> >> it returns the error
> >>
> >> mPDF error: Unable to create output file: cert.pdf
> >>
> >> 3. If I use this:
> >>
> >> $mpdf->Output('cert.pdf','D');
> >>
> >> it prompts for a directory and creates the PDF.
> >>
> >> UNFORUNATELY, #2 is what I need; has anyone had this issue, and if so,
> how did you resolve it? I've used this exact same page of code with another
> site and it worked fine... different server, but from what I can see, the
> web server isn't the issue.
> >>
> >> Thanks for any help; best,
> >>
> >> Bob Patin
> >> Longterm Solutions LLC
> >> bob at longtermsolutions.com
> >> 615-333-6858
> >> http://www.longtermsolutions.com
> >> FileMaker 9, 10 & 11 Certified Developer
> >> Member of FileMaker Business Alliance and FileMaker TechNet
> >> --
> >> Twitter: bobpatin
> >> Google+: http://www.longtermsolutions.com/plus
> >> AIM: longterm1954
> >> iChat: bobpatin
> >> --
> >> Expert FileMaker Consulting
> >> FileMaker Hosting for all versions of FileMaker
> >>
> >> _______________________________________________
> >> FX.php_List mailing list
> >> FX.php_List at mail.iviking.org
> >> http://www.iviking.org/mailman/listinfo/fx.php_list
> >>
> >
> > _______________________________________________
> > FX.php_List mailing list
> > FX.php_List at mail.iviking.org
> > http://www.iviking.org/mailman/listinfo/fx.php_list
>
> _______________________________________________
> FX.php_List mailing list
> FX.php_List at mail.iviking.org
> http://www.iviking.org/mailman/listinfo/fx.php_list
>
--
Regards
James Dcunha - Systems Engineer
jdcunha at supportgroup.com
(617) 252-8079 (Phone) (508) 653-2830 (fax)
<http://www.servoysupportgroup.com>www.supportgroup.com
Visit FileMaker: Explore, a free FileMaker resource for tips, tricks and
up-to-date information:
www.supportgroup.com/explore
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.iviking.org/pipermail/fx.php_list/attachments/20121226/389f4d9d/attachment.html
More information about the FX.php_List
mailing list