Hi Al, 

Well, as a java user with no PHP experience I'd have to say, I can't see why 
you think it's a java problem. So probably the java list couldn't help you much 
either...

Regards,
 
Georg Datterl
 
------ Kontakt ------
 
Georg Datterl
 
Geneon media solutions gmbh
Gutenstetter Straße 8a
90449 Nürnberg
 
HRB Nürnberg: 17193
Geschäftsführer: Yong-Harry Steiert 

Tel.: 0911/36 78 88 - 26
Fax: 0911/36 78 88 - 20
 
www.geneon.de
 
Weitere Mitglieder der Willmy MediaGroup:
 
IRS Integrated Realization Services GmbH:    www.irs-nbg.de 
Willmy PrintMedia GmbH:                            www.willmy.de
Willmy Consult & Content GmbH:                 www.willmycc.de 
-----Ursprüngliche Nachricht-----
Von: Al Dancer [mailto:[EMAIL PROTECTED] 
Gesendet: Dienstag, 25. November 2008 16:47
An: [email protected]
Betreff: Re: FOP to PDF using PHP

Hi again,

it seems that this is a Java issue:

here below is the extract of the fo2pdf.php code where my script exited:

*************************************************************************************
 function run($fo, $pdf = '', $DelFo = false)
    {
        $returnuri = false;
        if (!$pdf) {
            $pdf = tempnam($this->tmpdir, $this->tmppdfprefix);
            $returnuri = true;
        }
        $this->pdf = $pdf;
        $this->fo  = $fo;
        $options   = array();

        if ($this->configFile) {
            $options = array('-c', $this->configFile);
        }
        array_push($options, $this->fo, '-' . $this->renderer, $this->pdf);

        if (!$options = @new Java("org.apache.fop.apps.CommandLineOptions", 
$options)) {
          return PEAR::raiseError('Unable to create Java Virtual Machine in ' . 
__FILE__ . ':' . __LINE__, 11, PEAR_ERROR_RETURN, null, null);
        } // if
*************************************************************************************

So the script could not run : 
$options = @new Java("org.apache.fop.apps.CommandLineOptions", $options)

This may be should to the java mailing list :-(

thanks,

Al

--- On Tue, 11/25/08, Al Dancer <[EMAIL PROTECTED]> wrote:


        From: Al Dancer <[EMAIL PROTECTED]>
        Subject: Re: FOP to PDF using PHP
        To: [email protected]
        Date: Tuesday, November 25, 2008, 7:33 AM
        
        
Hello,

I've tried to change the Apache PATH environment, and this didn't help.

>From the php script I tried to create a file to the /tmp directory as:

$fp = fopen('/tmp/simple.txt', 'w+');
fwrite($fp, 'Try text file');
fclose($fp);

The file has been created, hence there no permission denied to /tmp

fo2pdf.php FO to pdf converter from PEAR
(info: http://pear.php.net/package/XML_fo2pdf/docs/latest/XML/XML_fo2pdf.html)

and the fop Home directory is : /opt/coolstack/fop ls -al /opt/coolstack/fop
drwxrwxrwx   9 webservd webservd     512 Nov 25 12:20 fop/

best regards,

Al

--- On Tue, 11/25/08, Luis Ferro <[EMAIL PROTECTED]> wrote:


        From: Luis Ferro <[EMAIL PROTECTED]>
        Subject: Re: FOP to PDF using PHP
        To: [email protected], [EMAIL PROTECTED]
        Date: Tuesday, November 25, 2008, 7:11 AM
        
        
        I've no idea what you are trying to do...
        
        What is behind the "XML/fo2pdf.php" file?
        
        I'd used the javabridge (an older version true) with FOP (also an older 
version 0.94 if i recall correctly), and i had it setup to work with tomcat as 
application server. I found it needed so that i could increase the memory for 
the processing threads...
        
        If on that file there are error trappings, disable them so that you get 
the full errors (or do some error trapping of what is going on), because 
something will be amiss.
        
        Also double check the paths, because you can't be sure where the path 
is really inside the several layers.
        
        [you can be trying to produce the pdf, but inside fop, the path of the 
file can, be for instance, pointing to the directory where fop is installed.
        
        Keep us posted...
        
        ;)
        
        
        On Tue, Nov 25, 2008 at 2:22 PM, Al Dancer <[EMAIL PROTECTED]> wrote:
        

Hello,

thank you for your answer.

Everyone has full access to the directory /tmp (read, write, execute for all) 
ls -al /tmp
drwxrwxrwt   7 root     sys         3388 Nov 25 14:42 tmp/

I have set PATH to /usr/local/bin:/usr/sbin:/usr/bin in Apache environment. 
I'll try to add there /opt/coolstack/apache2/bin:/usr/php5/bin etc...
and will see.

Al

--- On Tue, 11/25/08, Jean-François El Fouly <[EMAIL PROTECTED]> wrote:


        From: Jean-François El Fouly <[EMAIL PROTECTED]>
        Subject: Re: FOP to PDF using PHP
        To: [email protected]
        Date: Tuesday, November 25, 2008, 5:51 AM


        paul womack
         a écrit :
        >
        > Permissions, file paths, or $PATH errors would be the usual
        > suspects.
        >
        >   BugBear
        In particular, I remember that we had to change permissions to write in 
        the user's home directory, and IIRC this is related to font caching.
        
        
        ---------------------------------------------------------------------
        To unsubscribe, e-mail: [EMAIL PROTECTED]
        
        For additional commands, e-mail: [EMAIL PROTECTED]
        






---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to