PHP-Java Integration

Discussion in 'PHP' started by joan_ayala, May 6, 2006.

  1. #1
    I am using PHP 5.1.2 with Windows, and i think Java it is already integrated
    in it with no need of installing any extension, is that true ? or should i
    modify php.ini ? if so, how ?

    The problem is when the following line from a PHP file is executed:

    $system = new Java('java.lang.System');

    then next error is displayed:

    Fatal error: Class 'Java' not found in C:\wamp\www\trec\java.php on line 3

    hope you can help me. thanks
     
    joan_ayala, May 6, 2006 IP
  2. pwaring

    pwaring Well-Known Member

    Messages:
    846
    Likes Received:
    25
    Best Answers:
    0
    Trophy Points:
    135
    #2
    According to the documentation:

    "This PECL extension is not bundled with PHP."

    "Windows users will enable php_java.dll inside of php.ini in order to use these functions."

    So I'm guessing you have to enable it in php.ini somewhere. I'm afraid that I can't tell you exactly how because I don't use PHP on Windows, nor have I ever tried intergrating PHP with Java (personally that sounds like you're asking for trouble).

    Oh, and you may also want to upgrade to PHP 5.1.4, there's been an awful lot of bug fixes since 5.1.2.
     
    pwaring, May 8, 2006 IP
  3. eichpo97

    eichpo97 Peon

    Messages:
    1
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Hello!

    I'am with the same problem....ahve you already fix it?
    If so, tell me how please!
    Thanks!
     
    eichpo97, May 16, 2006 IP