/    Sign up×
Community /Pin to ProfileBookmark

i want to call java from php:
$salesTax = new Java(“SalesTax”);

// Don’t forget to typecast in order to
// conform with the Java method specifications.
$price=100;
$tax=18;
$price = (double) $price;
$tax = (double) $tax;

print $salesTax->SalesTax($price, $tax);
Code:

but i get this error:

[code]Fatal error: Unable to load Java Library C:PHPjavaclass, error: The specified module could not be found. in C:Program FilesApache GroupApache2htdocstestjava2.php on line 3
[/code]

and i have compiled the class and its working ok!
what to do?
this is my php.ini :

[code][Java]
java.class.path = “C:PHPextensions”;
java.home = “C:j2sdk1.4.1_06bin”;
java.library = “C:PHPjavaclass”;
java.library.path = .
[/code]

to post a comment
PHP

0Be the first to comment 😎

×

Success!

Help @pelegk1 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.8,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...