PHP, how to execute a Java program
|
عضو فعال
تاريخ التسجيل: 2006-02-27 مشاركات: 175
الجامعة: تشرين الكلية: الهندسة المعلوماتية المرحلة: متخرج الاختصاص: هندسة برمجيات
|
Hey all,
I have a problem calling a Java program from PHP script.
I tried the following:
exec('java Foo'); System('java Foo'); Shell_exec('java Foo');
where Foo is a main class located in the CLASSPATH.
I also tried:
$WshShell = new COM("WScript.Shell"); $oExec = $WshShell->Run("java Foo", 3, false);
but it makes Apache hang and wait the process to finish.
And I tried the Java-PHP bridge but for some reason, it makes Apache does a fatal error and terminates.
Any ideas?it's urgent!
|
| |
دخول أو تسجيل لإرسال التعليقات | قراءة: 255 |
|
عضو فعال
تاريخ التسجيل: 2006-12-01 مشاركات: 276
|
actuallyi have not try this any more this link may helps you
How Perfect You are O Allah, and I praise You. LA Ilah Ila Lah, I seek Your forgiveness and turn to You in repentance
|
| |
دخول أو تسجيل لإرسال التعليقات |
|
عضو فعال
تاريخ التسجيل: 2006-02-27 مشاركات: 175
الجامعة: تشرين الكلية: الهندسة المعلوماتية المرحلة: متخرج الاختصاص: هندسة برمجيات
|
I've tried all the ways explained in that manual, but no use 
I'll try to figure out something, maybe using JNI to implement the methods I need from Java packages in C++ then exec the C++ utility through PHP (What a twist!)
Thank you for your concern.
|
| |
دخول أو تسجيل لإرسال التعليقات |
|