Solved

PHP - Java

Posted on 2001-07-20
2
226 Views
Last Modified: 2012-08-14
Hello,
  I am using php 4.06 on Windows NT 4.0. My problem is whenever I want to use Java in PHP following error is displayed:

////////////////////
Fatal error: java.lang.UnsatisfiedLinkError: no php_java in java.library.path in E:\WWWROOT\PHP\JVER.PHP on line 4
//////////////////

I followed all the steps to necessary to invoke java but I am unable to do it. This problem has been faced by many like me and I have found no solution to it.
Please tell me what are the steps needed to solve this problem and what should be settings in php.ini file.

Sukhwinder Singh
0
Comment
Question by:Sukhwinder Singh
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 4

Accepted Solution

by:
ykf2000 earned 50 total points
ID: 6304111
Hi I think you need to do some setting on your php.ini. PHP need to know where is your Java Extension installed. Here is an example of settings.

http://zez.org/article/articleview/26/
0
 

Author Comment

by:Sukhwinder Singh
ID: 6305456
Hello,
 Thanks for your help even though I had already read that readme file that was provided eariler with java extension as mentioned in that article. But these days php_java.dll is present in extensions directory and isn't available as separate extension.

But I have found solution by trial and error. I wanted to write this because I thought it may help others like me.

My problem was that in php.ini there were four lines under Java Section:

///////////////////////////////////////////
extension=php_java
[Java]
java.class.path = c:\php\java\php_java.jar
java.home = d:\jdk1.3
java.library = d:\jdk1.3\jre\bin\hotspot\jvm.dll
java.library.path=C:\php\extensions
//////////////////////////////////////////

To solve this problem I had to remove fourth line under [Java] section.
So to run java from php we need these settings in php.ini:

///////////////////////////////////////
extension=php_java
[Java]
java.class.path = c:\php\java\php_java.jar
java.home = d:\jdk1.3
java.library = d:\jdk1.3\jre\bin\hotspot\jvm.dll
//////////////////////////////////////////////
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Can't Find the Homepage on my site 4 46
How to close my php post page. 3 42
integrated two Separate file . 3 30
Position image fpdf 4 18
These days socially coordinated efforts have turned into a critical requirement for enterprises.
This article discusses four methods for overlaying images in a container on a web page
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn how to count occurrences of each item in an array.

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question