php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #32215 Java Crash
Submitted: 2005-03-07 10:43 UTC Modified: 2005-05-09 10:53 UTC
Votes:11
Avg. Score:5.0 ± 0.0
Reproduced:11 of 11 (100.0%)
Same Version:0 (0.0%)
Same OS:0 (0.0%)
From: albaity at hotmail dot com Assigned:
Status: Wont fix Package: Feature/Change Request
PHP Version: 5.0.3 OS: Win XP Pro
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: albaity at hotmail dot com
New email:
PHP Version: OS:

 

 [2005-03-07 10:43 UTC] albaity at hotmail dot com
Description:
------------
try this code on 4.3.10 is work :
<?php
 // get instance of Java class java.lang.System in PHP
 $system = new Java('java.lang.System');

 // demonstrate property access
 print 'Java version='.$system->getProperty('java.version').' <br>';
 print 'Java vendor=' .$system->getProperty('java.vendor').' <br>';
 print 'OS='.$system->getProperty('os.name').' '.
             $system->getProperty('os.version').' on '.
             $system->getProperty('os.arch').' <br>';

 // java.util.Date example
 $formatter = new Java('java.text.SimpleDateFormat',
                       "EEEE, MMMM dd, yyyy 'at' h:mm:ss a zzzz");

 print $formatter->format(new Java('java.util.Date'));
?>

but with php5.0.3 is not work .


Reproduce code:
---------------
windows give me 2 message to terminate program because of memory crash .

Expected result:
----------------
give me the date

Actual result:
--------------
nothing CGI HEADERS NOT SEND IIS 5.5

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2005-03-07 20:38 UTC] albaity at hotmail dot com
this the result must appear : 
Java version=1.4.2_05 
Java vendor=Sun Microsystems Inc. 
OS=Windows XP 5.1 on x86 
???????, ???? 07, 2005 at 10:08:00 ? Arabia Standard Time
-----------------------------------------------------------
this is the code that I am test : 
<?php
 // get instance of Java class java.lang.System in PHP
 $system = new Java('java.lang.System');

 // demonstrate property access
 print 'Java version='.$system->getProperty('java.version').' <br>';
 print 'Java vendor=' .$system->getProperty('java.vendor').' <br>';
 print 'OS='.$system->getProperty('os.name').' '.
             $system->getProperty('os.version').' on '.
             $system->getProperty('os.arch').' <br>';

 // java.util.Date example
 $formatter = new Java('java.text.SimpleDateFormat',
                       "EEEE, MMMM dd, yyyy 'at' h:mm:ss a zzzz");

 print $formatter->format(new Java('java.util.Date'));
?>
---------------------------------------------------------
this is my php.ini setting which work with me with 4.3.10 :

java.class.path = "C:\PHP\ext\php_java.jar;C:\PHP\ext\itext.jar"
java.home = "C:\j2sdk\jre\"
java.library = "c:\j2sdk\jre\bin\server\jvm.dll "
java.library.path = "C:\PHP\ext\"
----------------------------------------------------
What I get : 
2 windows give me this message :
the instruction at "0x7c918fea" referennced memory at "0x00000010" the memory could not be "written"
 [2005-05-09 10:53 UTC] andrey@php.net
ext/java is no more maintained. Please try PHP-Java Bridge :
http://php-java-bridge.sourceforge.net/

Thank you
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Mon Jul 01 10:01:29 2024 UTC