I am trying to get Java to work from within PHP. I have been looking at:
The error and line of PHP code:
$system = new Java('java.lang .System');
Fatal error: Class 'Java' not found in C:\Documents and Settings\Ed
Taylor\My Documents\Proje cts Eclipse\workspa ces\workspace
PHP\Scrapboard\ JavaExample.php on line 3
I have looked at the 'User Contributed Notes'. It seems there is a
proliferative of different way people have defined the Java
configuration options. Some have links in quotes some do not. Not sure
if I am suppose to use the eight byte Windows dir name?
I am a Java programmer. Sun's JAVA_HOME points to the base directory
name for the JDK installed. In PHP it looks like it points to the bin
subdirectory.
This is what is documented:
java.class.path The path and name of the PHP jar file (usually called
php_java.jar) as well as any other jar files or
directories where PHP will search for compiled
Java classes.
java.home The root directory of the installed JDK
java.library The location of the Java virtual machine library
java.library.pa th The location of the PHP java library (usually in the
modules/ directory)
This is what I have defined in my PHP.ini:
extension=php_j ava.dll
java.class.path = "C:\php5.2\ext\ php_java.jar"
java.home = "C:\Program Files\Java\jdk1 .5.0_07"
java.library = "C:\Program
Files\Java\jdk1 .5.0_07\jre\bin \server\jvm.lib "
java.library.pa th = "C:\php5.2\ ext"
I am running:
- Windoze XP SP 2
- PHP 5.2
- Java JDK and JRE 1.5.0_07
- Eclipse 3.2
- PHPEclipse 0.2.0
Anyone point me in the right direction.
Thanks in Advance...
IchBin, Pocono Lake, Pa, USA http://weconsultants.phpnet.us
_______________ _______________ _______________ _______________ ______________
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)
The error and line of PHP code:
$system = new Java('java.lang .System');
Fatal error: Class 'Java' not found in C:\Documents and Settings\Ed
Taylor\My Documents\Proje cts Eclipse\workspa ces\workspace
PHP\Scrapboard\ JavaExample.php on line 3
I have looked at the 'User Contributed Notes'. It seems there is a
proliferative of different way people have defined the Java
configuration options. Some have links in quotes some do not. Not sure
if I am suppose to use the eight byte Windows dir name?
I am a Java programmer. Sun's JAVA_HOME points to the base directory
name for the JDK installed. In PHP it looks like it points to the bin
subdirectory.
This is what is documented:
java.class.path The path and name of the PHP jar file (usually called
php_java.jar) as well as any other jar files or
directories where PHP will search for compiled
Java classes.
java.home The root directory of the installed JDK
java.library The location of the Java virtual machine library
java.library.pa th The location of the PHP java library (usually in the
modules/ directory)
This is what I have defined in my PHP.ini:
extension=php_j ava.dll
java.class.path = "C:\php5.2\ext\ php_java.jar"
java.home = "C:\Program Files\Java\jdk1 .5.0_07"
java.library = "C:\Program
Files\Java\jdk1 .5.0_07\jre\bin \server\jvm.lib "
java.library.pa th = "C:\php5.2\ ext"
I am running:
- Windoze XP SP 2
- PHP 5.2
- Java JDK and JRE 1.5.0_07
- Eclipse 3.2
- PHPEclipse 0.2.0
Anyone point me in the right direction.
Thanks in Advance...
IchBin, Pocono Lake, Pa, USA http://weconsultants.phpnet.us
_______________ _______________ _______________ _______________ ______________
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)
Comment