You can subscribe to this list here.
2004 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(6) |
Oct
(6) |
Nov
(8) |
Dec
(2) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2005 |
Jan
(19) |
Feb
(15) |
Mar
(10) |
Apr
(8) |
May
(7) |
Jun
(9) |
Jul
(13) |
Aug
(31) |
Sep
(111) |
Oct
(52) |
Nov
(72) |
Dec
(42) |
2006 |
Jan
(21) |
Feb
(32) |
Mar
(33) |
Apr
(24) |
May
(15) |
Jun
(40) |
Jul
(32) |
Aug
(19) |
Sep
(38) |
Oct
(37) |
Nov
(63) |
Dec
(37) |
2007 |
Jan
(18) |
Feb
(39) |
Mar
(69) |
Apr
(49) |
May
(71) |
Jun
(59) |
Jul
(71) |
Aug
(85) |
Sep
(46) |
Oct
(14) |
Nov
(25) |
Dec
(56) |
2008 |
Jan
(24) |
Feb
(77) |
Mar
(104) |
Apr
(44) |
May
(41) |
Jun
(11) |
Jul
(31) |
Aug
(59) |
Sep
(44) |
Oct
(86) |
Nov
(66) |
Dec
(93) |
2009 |
Jan
(88) |
Feb
(41) |
Mar
(49) |
Apr
(135) |
May
(22) |
Jun
(31) |
Jul
(60) |
Aug
(71) |
Sep
(76) |
Oct
(18) |
Nov
(52) |
Dec
(20) |
2010 |
Jan
(8) |
Feb
(50) |
Mar
(35) |
Apr
(48) |
May
(46) |
Jun
(84) |
Jul
(38) |
Aug
(61) |
Sep
(51) |
Oct
(31) |
Nov
(17) |
Dec
(18) |
2011 |
Jan
(51) |
Feb
(14) |
Mar
(17) |
Apr
(23) |
May
(15) |
Jun
(11) |
Jul
(5) |
Aug
(5) |
Sep
(15) |
Oct
(8) |
Nov
(5) |
Dec
(25) |
2012 |
Jan
(2) |
Feb
(4) |
Mar
(6) |
Apr
(9) |
May
(27) |
Jun
(32) |
Jul
(36) |
Aug
(10) |
Sep
(16) |
Oct
(3) |
Nov
(13) |
Dec
(7) |
2013 |
Jan
(1) |
Feb
(4) |
Mar
|
Apr
(1) |
May
|
Jun
(2) |
Jul
|
Aug
(1) |
Sep
(4) |
Oct
(2) |
Nov
(1) |
Dec
|
2014 |
Jan
|
Feb
|
Mar
(2) |
Apr
(1) |
May
(2) |
Jun
(9) |
Jul
(5) |
Aug
(2) |
Sep
(4) |
Oct
|
Nov
|
Dec
|
2015 |
Jan
(3) |
Feb
(2) |
Mar
(4) |
Apr
(3) |
May
(1) |
Jun
(2) |
Jul
|
Aug
(2) |
Sep
(5) |
Oct
(1) |
Nov
|
Dec
|
2016 |
Jan
|
Feb
(5) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(5) |
Sep
(3) |
Oct
|
Nov
|
Dec
|
2017 |
Jan
(6) |
Feb
|
Mar
|
Apr
(10) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
(1) |
Dec
|
2018 |
Jan
(2) |
Feb
(5) |
Mar
|
Apr
|
May
(1) |
Jun
(3) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2019 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
(1) |
Aug
(1) |
Sep
|
Oct
|
Nov
|
Dec
|
2020 |
Jan
|
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(2) |
Oct
|
Nov
|
Dec
|
2021 |
Jan
(5) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2023 |
Jan
|
Feb
(2) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Peter N. <pn...@kr...> - 2005-08-22 09:49:34
|
Hi there, as some of you might know debian is moving the testing/unstable distribution to a new default compiler(gcc 3.x -> gcc 4). So far compiling the bridge has always been a pleasure. ;) Yesterday I updated to gcc 4. Now the bridge complains: configure: WARNING: YOUR GCC INSTALLATION IS BROKEN. It tries to link with the same library for -m32 and -m64 builds. This may result in a "wrong ELF class" error at runtime. Although you can work around this bug at runtime by changing the LD_LIBRARY_PATH, we recommend to re-install the gcc compiler before youcontinue to install the PHP/Java Bridge. I think it should be possible to set the compiler-version via EXPORT CC=gcc-3.3 but this seems not to work, probably becaus CC is set to gcc in the Makefile. I know this is most likely my fault or a problem with debian, still I would appreciate if anyone of you got a hint to solve this. Thx, Peter |
From: Jost B. <jos...@ya...> - 2005-08-21 12:14:09
|
Hi, a preview version of 2.0.8 is available for download: http://prdownloads.sourceforge.net/php-java-bridge/php-java-bridge_2.0.8pre3.zip?download (The above download is for windows only, on Linux/Unix please download the code directly from the CVS repository: cvs -z3 -d:pserver:ano...@cv...:/cvsroot/php-java-bridge co php-java-bridge) For production systems please use version 2.0.7 instead. The following features were added: * JSP, PHP session sharing * GUI support * Calling PHP from java, see the examples/XML example. Changes since 2.0.8pre * Local channel re-directs work correctly now. This means that, when deployed in Apache/Tomcat, Apache/PHP and the PHP/Java Bridge 2.0.8 deliver content more than 50 times faster than version 2.0.7 and about 30% faster than tomcat's own engine via Apache/mod_jk: time for i in `seq 200`; do wget -o/dev/null -O/dev/null http://localhost:8000/JavaBridge/sessionSharing.jsp; done real 0m5.971s user 0m1.090s sys 0m0.420s time for i in `seq 200`; do wget -o/dev/null -O/dev/null http://localhost:8000/JavaBridge/sessionSharing.php; done real 0m4.351s user 0m1.140s sys 0m0.530s (RHEL3, kernel 2.4.21 on a 1.5GHZ amd32, latest versions of PHP/Java Bridge, Tomcat/mod_jk and Apache. * On windows: Starting the backend automatically should work correctly now when the path ends with a slash. * The CGI servlet has been rewritten and it delivers content much faster now. However, running PHP as a CGI from tomcat is not recommended. Please use Apache and the mod_jk connector instead of connecting tomcat directly to the internet. This is much faster and more secure. * Several other bugfixes, please see changelog. I will release the above code as 2.0.8 if I don't get bug reports within the next three weeks. Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: Jost B. <jos...@ya...> - 2005-08-19 17:26:18
|
Hi, > The phpinfo() function ran, and displayed this for > java : > > java support Enabled > java bridge 2.0.8pre > java.log_level 2 > java.hosts 127.0.0.1:8080 > java.servlet On > java command javaw -Djava.library.path=c:\php5 It seems that local channel re-directs currently do not work at all (at least not if there is no security manager). A workaround would be to switch it off in the backend by changing SocketRunner's isAvailable() to always return false. Or to kill it: telnet to port#9567 and send a <>, it will close the port immediately. It seems that the bug is connected with a recent "fix" in the OnInitSockname (in java.c), which now ignores the command to switch it off. -- When re-directing from a HTTP tunnel to a local TCP channel, it is necessary to switch off the local "unix domain" channel. Otherwise the bridge tries to use this and fails. I think I can fix this tomorrow and update the download, it will be 2.0.8pre3. Thank you very much for the bug report! Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: Cameron B. <ca...@br...> - 2005-08-18 18:57:20
|
I managed to get the tomcat bridge working when running test.bat. However every php script that I run within tomcat fails to find the bridge. Here is the process that I took Unzipped php-java-bridge_2.0.8pre.zip into c:\php5 Eited c:\php5\php.ini extension_dir = "c:\php5" extension = php_java.dll [java] #java.socketname java.hosts="127.0.0.1:8080" java.servlet=On Deployed JavaBridge.war into tomcat-5.5.9 Browsed http://localhost/test.php The phpinfo() function ran, and displayed this for java : java support Enabled java bridge 2.0.8pre java.log_level 2 java.hosts 127.0.0.1:8080 java.servlet On java command javaw -Djava.library.path=c:\php5 -Djava.class.path=c:\php5/JavaBridge.jar -Djava.awt.headless=true php.java.bridge.JavaBridge INET_LOCAL:9267 2 "" java status not running java server localhost And shows this at the bottom : Fatal error: php_mod_java(52): Could not connect to server: Unknown error -- Have you started the java bridge and set the java.socketname option? in C:\java\jakarta-tomcat-5.5.9\webapps\JavaBridge\test.php on line 19 I have tried editing JavaBridge/WEB-INF/web.xml to change things like override_hosts, servlet_log_level to try and get it working. Any hints ? Thanks, Cameron. |
From: Jost B. <jos...@ya...> - 2005-08-17 17:38:11
|
Hi, > installation. Next day, after the restarting of > windows, I received the > following error: > > <br /> > > <b>Fatal error</b>: php_mod_java(52): Could not > connect to server: No error Please start the backend *before* you start the web-server. How you do this is currently up to you: you could put a startup script into the autostart folder or you could use tomcat to start the backend as a service. (In version 2.0.8 the backend starts automatically if the PHP/Java Bridge was deployed as an apache module. But I would not recommend this setup, neither on unix nor on windows.) I hope it helps. If not, please create a bug report. I will add a service script to start java as a windows service for version 2.0.9. Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: <Y.L...@ho...> - 2005-08-17 13:00:37
|
Dear Sir! =20 I have installed java-bridge for PHP in windows XP. It worked properly = after installation. Next day, after the restarting of windows, I received the following error: <br /> <b>Fatal error</b>: php_mod_java(52): Could not connect to server: No = error -- Have you started the java bridge and set the java.socketname option? in <b>C:\AccessPoint\www\temp\javatest.php</b> on line <b>6</b><br /> =20 phpInfo data: java support Enabled =20 java bridge 2.0.7 =20 java.hosts no value =20 java.servlet Off =20 java status not running =20 java server localhost =20 =20 I also tried to run script java -jar JavaBridge.jar [INET:9267 4 JavaBridge.log]. which I have found in one forum. All my attempts had no effects :-( =20 Could you help me with this problem? =20 --------------------------------------------- Best regards, Yaroslav Latushkin, Programmer, HOST Corporate Systems, LLC =20 phone: +7(343) 216-16-30 ext. 1605 fax: +7(343) 216-16-31 e-mail: Y.L...@ho... <mailto:Y.L...@ho...>=20 icq =B9 119-670-561 =20 |
From: Jost B. <jos...@ya...> - 2005-08-11 18:36:19
|
Hi, I could reproduce this problem. Please see PR1256962 for details (https://sourceforge.net/tracker/index.php?func=detail&aid=1256962&group_id=117793&atid=679233). As a workaround please copy your libraries (.jar files) into the %JAVA_HOME%\jre\lib\ext folder and re-start the servlet engine after that or please copy them to the JavaBridge\WEB-INF\lib directory (the directory already contains the JavaBridge.jar library). I have corrected this problem for version 2.0.8, please see http://prdownloads.sourceforge.net/php-java-bridge/php-java-bridge_2.0.8pre.zip?download If you extract the zip file to c:\php5 and then copy c:\php5\JavaBridge.war into the servlet engine's webapps folder, you can run the examples via http://localhost:8080/JavaBridge. I have just tested this with tomcat5 (standalone), and it works correctly now. (The excel example tests the java_require functionality) Thank you very much for reporting this bug. Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: David J. <da...@jo...> - 2005-08-11 14:59:02
|
Hi, =20 I am new to java so please excuse me if I am asking a stupid question. My problem is I cannot access my own java class files from php. =20 My OS is Windows XP I have PHP 5.0.3 running on Apache 2.0.54 with module mod_jk2. I have deployed javabridge 2.0.7 under tomcat 5.5.9., using the excellent instructions at: =20 http://mpcon.org/apacheguide/=20 =20 I can use built in classes such as getProperty('java.version') of 'java.lang.System', but the simplest application I can think of returns the error "ClassNotFoundException: Class HelloPhp not found" =20 The PHP code: =20 <?php java_set_library_path("%CATALINA_HOME%\webapps\JavaBridge\WEB-INF\classe s\php\java\servlet"); $useless =3D new Java_class('HelloPhp'); $result =3D$useless->HelloPhp(); echo $result; ?> =20 The HelloPhp.java class code: =20 // HelloPHP.java test of JavaBridge =20 public class HelloPhp { public static String main() { return "Hello PHP" ; } } =20 I have tried placing the class HelloPhp.class file in every directory I can think of, with/without corresponding java_set_library_path('..') but to no avail. The class works from a test calling program from the system prompt, provided the CLASSPATH environmental variable is set. =20 The reason for thinking the above path is the most likely candidate is I have noticed that if I restart Tomcat I get once only the error: =20 "ReferenceClass failed: new HelloPhp. Cause: java.lang.IllegalArgumentException] thrown" however refreshing the page reverts to the above "ClassNotFoundException:" =20 Any help would be much appreciated. =20 David =20 |
From: Thomas K. <tk...@da...> - 2005-08-11 14:10:52
|
Abbett, Jonathan wrote: >> A method I use returns a "List" of objects. I, with my developer's >> omniscience, know that each object in the list is of a particular class. >> How do I cast my object to that class? I don't have very much experience with the java bridge, but as far as I know you don't need to cast java objects in php. >> The Java code I'm basing this on simply looks like: >> >> List fooList = getFooList(); >> MyClass foo = (MyClass)fooList.get(0); >> >> >> I'm stumped as to write the PHP analog. My guess: $SomeObject = java('full.package.path.to.SomeObject'); $fooList = $SomeObject->getFooList(); $foo = $fooList->get(0); _Should_ be as simple as that. I hope I could help, Thomas |
From: Alison S. <al...@ba...> - 2005-08-10 21:07:51
|
Hi, I contacted this list a couple of weeks ago about using php-java-bridge to fire Crystal Reports from Drupal. I have the following: Crystal Reports jar files Crystal Reports jsp examples Drupal Module with jsp examples semi-translated to php In general, this project is kicking my ass and my boss so has his heart set on being able to fire reports from Drupal that is has authorized me to find a paid consultant to get one example working. If you are interested in this job please email me credentials and hourly rate. Alison |
From: Abbett, J. <Jon...@ch...> - 2005-08-10 15:45:52
|
A method I use returns a "List" of objects. I, with my developer's omniscience, know that each object in the list is of a particular class. How do I cast my object to that class? The Java code I'm basing this on simply looks like: List fooList =3D getFooList(); MyClass foo =3D (MyClass)fooList.get(0); I'm stumped as to write the PHP analog. Thanks, Jon =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D Jonathan Abbett Children's Hospital Informatics Program 1 Autumn Street, Fifth Floor Boston, MA 02215 617-355-8334 http://www.chip.org |
From: Jost B. <jos...@ya...> - 2005-08-09 18:18:17
|
Hi, this has been implemented in version 2.0.8. A preview is at http://prdownloads.sourceforge.net/php-java-bridge/php-java-bridge_2.0.8pre.zip?download Please see the examples/XML for an example how to call php code from java. The trick is to write a java class which calls your PHP functions. On java level you can catch the PHP exceptions and decide what to call next: interface Proc { public void f(); public void e(Exception e); class test { public void call (Proc p) { try { p.f(); } catch (Exception e) { p.e(e); } } <?php function f() { new java("java.lang.String", null); echo "never reached"; } function e($e) { echo "an exception occured on php level: $e"; } $test=new java('Proc$Test'); $test->call(java_closure()); ?> Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: Jost B. <jos...@ya...> - 2005-08-05 18:20:05
|
Hi, a extermal class is missing, so the bridge was not able to invoke the constructor, it has returned the class instead. You should be able to locate the error message in the bridge log file. > So apparantly, as to see in the first line, $dataset > is indeed on object Objects are displayed as ...@hashCode, classes as class:<name>. But you're right that the message is not clear enough. I will change the error message for the next version. Your next question is probably what the NoClassDefFoundError means, we have an open problem report for this (it's a problem specific to the sun platform, other platforms such as ecma335 and gnu java don't have this problem). Kai has already addressed one part of the problem with his dynamic class loader which does not confuse classes loaded from different url classloaders anymore. However, the fundamental problem cannot be fixed by us, this is something that sun must handle. But it should be easy to avoid the problems if one obeys the following rules: * All interconnected classes must be accessible by the same classloader. This means that all interconnected classes must be loaded by the same java_require() call. java_require(foo); java_require(bar); does not work if foo and bar reference each other. This condition stays the same unless you stop the bridge or call java_reset(). (Reason is that even if you use java_require(foo;bar) after that, the loader has already cached the broken foo and the queries for bar jump off from there). * No class may be appear in more than java_require() statement call within the same php script. Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: Thomas K. <tk...@da...> - 2005-08-05 14:12:41
|
Hello everybody, I'm trying to use the excellent jfree project JFreeChart (http://www.jfree.org/jfreechart/index.php) to generate a few barcharts. Unfortunately I get an error and don't know whats wrong. Here's the code I use (as an example, to provoce the error): <? java_require("jfreechart-1.0.0-rc1.jar"); $dataset = new Java("org.jfree.data.category.DefaultCategoryDataset"); print $dataset; print $dataset->hashCode(); ?> This is what I get: ----------------- snip --------------------------------------------- [class java.lang.String: First][class org.jfree.data.category.DefaultCategoryDataset: class org.jfree.data.category.DefaultCategoryDataset] Fatal error: Uncaught [class java.lang.Exception: java.lang.Exception: Invoke failed: [class org.jfree.data.category.DefaultCategoryDataset]->hashCode. Cause: java.lang.IllegalArgumentException: object is not an instance of declaring class] thrown in /mnt/data/var/www/localhost/htdocs/java.php on line 23 ----------------- snap --------------------------------------------- So apparantly, as to see in the first line, $dataset is indeed on object of the class DefaultCategorySet. But invoking a method on this object results in an error "object is not an instance of declaring class". What's wrong? Is this a bug in the bridge or did I do something wrong? Thanks Thomas |
From: Thomas K. <tk...@da...> - 2005-08-05 13:40:04
|
Hello everybody, I'm trying to use the excellent jfree project JFreeChart (http://www.jfree.org/jfreechart/index.php) to generate a few barcharts. Unfortunately I get an error and don't know whats wrong. Here's the code I use (as an example): <? java_require("jfreechart-1.0.0-rc1.jar"); $dataset = new Java("org.jfree.data.category.DefaultCategoryDataset"); print $dataset; print $dataset->hashCode(); ?> This is what I get: ----------------- snip --------------------------------------------- [class java.lang.String: First][class org.jfree.data.category.DefaultCategoryDataset: class org.jfree.data.category.DefaultCategoryDataset] Fatal error: Uncaught [class java.lang.Exception: java.lang.Exception: Invoke failed: [class org.jfree.data.category.DefaultCategoryDataset]->hashCode. Cause: java.lang.IllegalArgumentException: object is not an instance of declaring class] thrown in /mnt/data/var/www/localhost/htdocs/java.php on line 23 ----------------- snap --------------------------------------------- So apparantly, as to see in the first line, $dataset is indeed on object of the class DefaultCategorySet. But invoking a method on this object results in an error "object is not an instance of declaring class". What's wrong? Is this a bug in the bridge or did I do something wrong? Thanks Thomas |
From: Jost B. <jos...@ya...> - 2005-08-04 19:05:17
|
Hi Jonathan, > Is there a PHP 4 alternative to using PHP 5's > try/catch functionality to catch Java exceptions? Currently only java_last_exception(). But funny that you mention it, I have just thought about this while trying to do the opposite: find a way to signal an exception while running a PHP procedure invoked from java. I think there are at least two solutions, we could either add a primitive to register a "global" exception handler, something like: java_register_exception_handler(php_proc); or we could add a special primitive "java_call_with_exception_handler" which wraps the current invoke, getsetprop or create call and invokes the handler in case we receive an exception- instead of an object-handle (the protocol uses E to tag an exception object). Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: Kai L. <K.L...@li...> - 2005-08-04 00:07:34
|
On Wed, 03 Aug 2005 12:06:19 -0500, you wrote: >I want to be able to store an object in $_SESSION so that I can retrive=20 >the object with subsequent php pages. I think the issue I'm having is=20 >due to an out of scope condition when the php page exits. I see the=20 >Cache reference in the docs and tests.php4/Cache.java in the=20 >distribution but I'm little fuzzy on what to actually do. > >Here is a code snippet followed by the exception that is raised when my=20 >php page exits: > >... > // OrderServiceUtil() handles the context lookup, remote object=20 >narrowing and home.create calls > $orderServiceUtil =3D new OrderServiceUtil(); > > // get an instance of the home interface of the session bean > $order =3D $orderServiceUtil->getInstance(); > > // get product id 1041=20 > = =20 > > $product =3D $order->getProduct(1041); > =20 > $_SESSION['product'] =3D $product; > =20 >... > >=20 >java.lang.NoSuchMethodException: __sleep(). Candidates: [] > at php.java.bridge.JavaBridge.Invoke(JavaBridge.java:966) > at php.java.bridge.Request.handleRequests(Request.java:190) > at php.java.bridge.JavaBridge.run(JavaBridge.java:142) > at php.java.bridge.ThreadPool$Delegate.run(ThreadPool.java:20) >=20 >Fatal error: Exception thrown without a stack frame in Unknown on line 0 > >Just looking over the java bridge code it appears it is performing a=20 >wait() which probably call a system specific sleep(). What I can't=20 >figure out is which class the invocation is attempted. wait() and=20 >sleep() should be in rt.jar. > >Any thoughts? Well, "__sleep()" is a magical method which PHP calls to signal to any object that it is going to be seralized soon ... it has nothing to do with java at all. And since your $product does not have a __sleep method, the invocation will fail. Serializing non-trivial objects in php is not for the faint of heart, you should know exactly what happens and when (for example the class definition needs to be loaded when the session gets started, *before* the object gets deserialized). Anyway, you can't just write a java object to your session. What you'll have to do is to use a java session. Look up the php java brigde docs at http://php-java-bridge.sourceforge.net/about about usage of java_get_session You could use session_start(); $java_session =3D java_get_session(session_id()); to get what you want .. MfG, Kai Londenberg ------------------------------- librics GmbH & Co. KG G=F6ttinger Chaussee 115 D-30459 Hannover Tel. +49 511 - 473 88 77 =46ax +49 511 - 473 88 78 mailto: K.L...@li... |
From: Abbett, J. <Jon...@ch...> - 2005-08-03 21:51:41
|
Is there a PHP 4 alternative to using PHP 5's try/catch functionality to = catch Java exceptions? =20 Thanks, Jon Abbett jon...@ch... |
From: Bryan L. <bl...@th...> - 2005-08-03 17:06:11
|
I want to be able to store an object in $_SESSION so that I can retrive the object with subsequent php pages. I think the issue I'm having is due to an out of scope condition when the php page exits. I see the Cache reference in the docs and tests.php4/Cache.java in the distribution but I'm little fuzzy on what to actually do. Here is a code snippet followed by the exception that is raised when my php page exits: ... // OrderServiceUtil() handles the context lookup, remote object narrowing and home.create calls $orderServiceUtil = new OrderServiceUtil(); // get an instance of the home interface of the session bean $order = $orderServiceUtil->getInstance(); // get product id 1041 $product = $order->getProduct(1041); $_SESSION['product'] = $product; ... java.lang.NoSuchMethodException: __sleep(). Candidates: [] at php.java.bridge.JavaBridge.Invoke(JavaBridge.java:966) at php.java.bridge.Request.handleRequests(Request.java:190) at php.java.bridge.JavaBridge.run(JavaBridge.java:142) at php.java.bridge.ThreadPool$Delegate.run(ThreadPool.java:20) Fatal error: Exception thrown without a stack frame in Unknown on line 0 Just looking over the java bridge code it appears it is performing a wait() which probably call a system specific sleep(). What I can't figure out is which class the invocation is attempted. wait() and sleep() should be in rt.jar. Any thoughts? |
From: Jost B. <jos...@ya...> - 2005-08-02 19:28:18
|
Hi, > I mean auto converting java.util.Hashmap to PHP > native array.. Autoconversion has been switched off in php5 by default because it is an expensive operation. But you can convert manually: java_get_values($map); It is a no-op in php4, please see tests.php5/java_get_values.php for details. On protocol level the behaviour can be switched off by setting bit1 to 0, see protocol.txt. In php5 we send 0304 and in php4 0306, see the function get_mode() in client.c Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: William L. <wil...@co...> - 2005-08-02 12:35:01
|
Hello, I've been trying to compile this module on my development web server for the company I work for. I can't get pass the "./configure" stage. It aborts with the following: [root@cooeps php-java-bridge-2.0.7]# ./configure --with-java=/usr/local/IBMJava2-142 ... ... checking for unistd.h... yes checking whether AF_LOCAL is declared... yes checking whether PF_LOCAL is declared... yes checking for socket in -lsocket... no checking for sem_init in -lrt... yes checking for pthreads_cflags... checking for pthreads_lib... configure: error: host_alias is not set. Make sure to run config.guess I then run "config.guess" and I get the following: i686-pc-linux-gnu I retry with configure but still it fails in the same part. Then I try adding the --host parameter to the configure script: [root@cooeps php-java-bridge-2.0.7]# ./configure --host=i686-pc-linux-gnu --with-java=/usr/local/IBMJava2-142 configure: WARNING: If you wanted to set the --build type, don't use --host. If a cross compiler is detected then cross compile mode will be used. checking for i686-pc-linux-gnu-gcc... no checking for gcc... gcc ... ... checking whether AF_LOCAL is declared... yes checking whether PF_LOCAL is declared... yes checking for socket in -lsocket... no checking for sem_init in -lrt... yes checking for pthreads_cflags... checking for pthreads_lib... checking for broken stdio buffering... no checking for broken gcc installation... no checking for abstract namespace... yes checking for struct ucred... yes configure: error: cannot run And here is where I am stuck. According to the project web page I am complying with the minimum version requests for the tools needed to make the build. I am using RedHat 9 with the following packages: - kernel-2.4.20-8 - JDK from IBM 1.4.2 (IBMJava2-142) - gcc-3.2.2-5 - apache 1.3.28 (compiled from source) - php 4.3.2 (compiled from source) - libtool-1.4.3-5 - automake-1.6.3-5 - make-3.79.1-17 - autoconf-2.57-3 What can I do? any ideas? The funny thing is that I configured the module successfully in my workstation with Fedora Core 3 and the latest updates. Thanx in advance, -William |
From: <Sup...@gm...> - 2005-08-02 09:01:02
|
Hi All is it possible returning as native Array from Java Class in PHP 5 ? I mean auto converting java.util.Hashmap to PHP native array.. thanks --=20 kamus online - http://kamus.landak.com/ |
From: Jost B. <jos...@ya...> - 2005-07-25 20:36:21
|
Hi, since a few people have asked how one could run PHP from java, I have created a tomcat example. Please download and install: http://php-java-bridge.sf.net/JavaBridge.war into your servlet engine. For tomcat5: Please start tomcat, then copy the .war file to the webapps directory and visit http://localhost:8080/JavaBridge and click on the supplied examples. If, for some reason php could not be found, please see webapps/JavaBridge/WEB-INF/cgi/README. Please also check the webapps/JavaBridge/WEB-INF/web.xml, especially the "override" flag. Switching it off improves performance dramatically. Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: Jost B. <jos...@ya...> - 2005-07-22 16:09:06
|
Hi, > Can I put JSP and PHP in the same file? Interesting question. I don't think it is possible at the moment. > 2) If not, how do I translate this line of jsp > to php? > response.sendRedirect("Viewer.php"); With: <?php header ('HTTP/1.1 301 Moved Permanently'); header ('Location: '.$txLocation); exit; ?> Please see the following URL for details: http://us2.php.net/manual/en/function.header.php Regards, Jost Boekemeier ___________________________________________________________ Gesendet von Yahoo! Mail - Jetzt mit 1GB Speicher kostenlos - Hier anmelden: http://mail.yahoo.de |
From: Alison S. <al...@ba...> - 2005-07-21 21:11:55
|
Hi, I have a whole bunch of JSP files I need to translate into PHP to work with PHP-Java-Bridge. So I have a couple of questions I hope you can help me with. 1) Can I put JSP and PHP in the same file? (this would be easiest for me) 2) If not, how do I translate this line of jsp to php? response.sendRedirect("Viewer.php"); Alison |