Simple Java problem
| From: | Martin | Date: | Wed, 06 Sep 2000 13:21:11 +0000 |
| Subject: | Simple Java problem | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-15527@lists.php.net to get a copy of this message | ||
Hi !
I got PHP Version 4.0.2 with the following configuration:
'./configure' '--with-apxs=/etc/httpd/bin/apxs'
'--with-pgsql=/usr/local/pgsql' '--enable-sysvshm=yes'
'--enable-sysvsem=yes' '--enable-bcmath=yes' '--with-imap'
'--enable-ftp'
'--with-pdflib=../pdflib-3.01/' '--without-mysql' '--with-gnu-ld'
'--with-java=/usr/jdk1.2' '--with-jpeg-dir=/usr/lib'
'--enable-versioning'
Okay. Someone told me that I could use java like this:
$system = new Java( "java.lang.System" );
print "Java Version: " . $system->getProperty( "java.version" );
So creating a class Java with the classname a the first parameter and
then calling it almost like a php-class.
When trying the code, I get:
Fatal error: Cannot instantiate non-existent class: java in javatest.php
on line 2
What is wrong ?
Martin