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
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
|
|
|
|
|
1
(1) |
2
(4) |
3
|
4
|
5
|
6
|
7
|
8
(1) |
9
|
10
(1) |
11
(1) |
12
(1) |
13
|
14
(1) |
15
|
16
|
17
(2) |
18
(9) |
19
|
20
|
21
|
22
|
23
|
24
|
25
|
26
(3) |
27
(2) |
28
(8) |
29
(3) |
30
(4) |
31
(5) |
|
|
|
|
|
From: <php...@li...> - 2010-05-31 20:21:52
|
It is now in CVS. From the NEWS file: Version 6.2.1 * $s = new java("java.lang.String", "hello"); $b = $s->getBytes("ASCII"); echo (string)$b; The (string) cast no longer converts the byte[] array to a java.lang.String using the encoding set with java_set_file_encoding() but returns the byte[] array as a PHP string without changing it. In previous versions one had to use java_cast($b, "string") to do a binary-safe conversion from byte[] to PHP string. * To support both x64 and 386 windows dll's, the layout has been changed: WEB-INF --- cgi | --- x86-windows --- conf.d --- mysql.ini [extension="php_mysql.dll"] | | | --- ext --- php_mysql.dll | --- php-cgi.exe <-- moved here | | | --- i386-linux --- conf.d --- mysql.ini [extension="mysql.so"] | --- ext --- mysql.so --- php-cgi <-- moved here |
From: <php...@li...> - 2010-05-31 15:13:33
|
[replying to myself] On 5/30/10, Jost Boekemeier <jos...@go...> wrote: > The api has two bugs: java_context()->call() invokeFunction(PhpProcedure) > should bring you back to where you came from. Doesn't work. Won't fix, at least not in version 6.1.2.x > And the wrapper for java_context()->call(), the > "java_call_with_continuation()" doesn't work Fixed in CVS head. => http://php-java-bridge.cvs.sourceforge.net/viewvc/php-java-bridge/php-java-bridge/server/php/java/script/InvocablePhpScriptEngine.java?r1=1.26&r2=1.27&sortby=date Regards, Jost Bökemeier |
From: <php...@li...> - 2010-05-31 15:00:48
|
Hi, >> you are calling procedures from the servlet package outside of a servlet >> environment. I am surprised that this works at all. > > I only attempted this so I could isolate the development of the Java to PHP > side from my servlet. Please use a servlet environment and use the methods from the EngineFactory to access the ScriptEngine. The JavaBridge.war example contains two examples: The http://php-java-bridge.cvs.sourceforge.net/viewvc/*checkout*/php-java-bridge/php-java-bridge/examples/php%2Bjsp/jsp%2Bphp.jsp show how to invoke methods in a (remote-) PHP application server. The other example http://php-java-bridge.cvs.sourceforge.net/viewvc/*checkout*/php-java-bridge/php-java-bridge/examples/php%2Bjsp/jsr223.jsp shows how to execute a PHP script in the current application server. > Why could I not reference an actual script file? What do you mean with this? When running in a servlet environment, you can. Please see the example above. > I tested the example you gave and it worked but the application hung. Is > that normal? I am sorry, but I cannot reproduce this problem using PHP/Java Bridge 6.1.2.1. >> Btw to avoid confusion: The engine key PhpProcedure is the environment >> that >> has been passed to the java continuation via java_context()->call(ENV) -- >> continuations are modeled as procedures, that's why it's called >> "PhpProcedure" > > I don't follow: is there some other key I should have used? I'm missing the > point here. None. You could have used invokeFunction() as well. > I'm now trying to get PHPJavaBridge deployed on my Jetty test server. I've > got the following setup: > > Jetty > lib > ext > JavaBridge.jar > php-script.jar > php-servlet.jar > script-api.jar > webapps > JavaBridge.war > java > Java.inc > > So when I try to browse http://localhost:8080/JavaBridge I get: > > Cannot access /java within the current web directory. Please ask the jetty maintainer for support. I am not going to support this setup. You have the same libraries deployed at two locations, within the web app and in the ext directory. Please either remove the .jar files from the ext folder and try again. Or please use Tomcat, which supports running our class files from a shared loader quite well. I think jetty fails to pass the web app root directory to the classes loaded from ext. But I am not going to debug this server, especially since I know that it has some issues. Regards, Jost Bökemeier |
From: <php...@li...> - 2010-05-31 14:45:59
|
Hi, [please excuse the delay] $javaOutputStream = new java("java.io.ByteArrayOutputStream"); $exportManager->exportReportToPdfStream($jasperPrint, $javaOutputStream); java_set_file_encoding("UTF-8"); print ((string)$javaOutputStream->toByteArray()); The (string) cast above invokes a byte[] => String conversion using the file encoding UTF-8. Since cp1252 is the codepage used by java, the result is invalid PDF. Please either avoid the byte[] => String conversion by using java_cast() or please use java_set_file_encoding("cp1252") Please change your code to [...] print (java_cast($javaOutputStream->toByteArray(), "string")); Whether or not the (string) cast should avoid the conversion and behave like java_cast() is another question. I think it should. But before we change it, we'll have to check carefully if this won't break compatibility. -- The __toString() method for proxy objects appeared in PHP 5.2.0, so I think a change won't break too much code. Thank you very much for reporting this issue. Regards, Jost Bökemeier |
From: <php...@li...> - 2010-05-31 13:24:52
|
Hi, > you are calling procedures from the servlet package outside of a servlet > environment. I am surprised that this works at all. I only attempted this so I could isolate the development of the Java to PHP side from my servlet. > Outside of a servlet env use: > > public static void main(String s[]) throws Exception { > ScriptEngine e = new ScriptEngineManager().getEngineByName("php-invocable"); > e.eval("<?php class X { public function f() {return 'hello';} } > java_context()->call(java_closure(new X())); ?>"); > System.out.println(((Invocable)e).invokeMethod(e.get("php.java.bridge.PhpProcedure"), > "f", new Object[]{})); > ((Closeable)e).close(); Why could I not reference an actual script file? I tested the example you gave and it worked but the application hung. Is that normal? > Btw to avoid confusion: The engine key PhpProcedure is the environment that > has been passed to the java continuation via java_context()->call(ENV) -- > continuations are modeled as procedures, that's why it's called > "PhpProcedure" I don't follow: is there some other key I should have used? I'm missing the point here. I'm now trying to get PHPJavaBridge deployed on my Jetty test server. I've got the following setup: Jetty lib ext JavaBridge.jar php-script.jar php-servlet.jar script-api.jar webapps JavaBridge.war java Java.inc So when I try to browse http://localhost:8080/JavaBridge I get: Cannot access /java within the current web directory. I have tried putting the java directory under Jetty, under lib and under ext but I get the same error. Any ideas? Thanks again, Bernard. _________________________________________________________________ View photos of singles in your area! Looking for a hot date? http://clk.atdmt.com/NMN/go/150855801/direct/01/ |
From: <php...@li...> - 2010-05-30 19:05:56
|
The api has two bugs: java_context()->call() invokeFunction(PhpProcedure) should bring you back to where you came from. Doesn't work. And the wrapper for java_context()->call(), the "java_call_with_continuation()" doesn't work anymore since the last security fix. :( On May 30, 2010 8:33 PM, "Jost Boekemeier" <jos...@go...> wrote: Btw to avoid confusion: The engine key PhpProcedure is the environment that has been passed to the java continuation via java_context()->call(ENV) -- continuations are modeled as procedures, that's why it's called "PhpProcedure" > > On May 30, 2010 8:18 PM, "Jost Boekemeier" < jos...@go...> wrote: > > Hi, > > ... > > public static void main(String s[]) throws Exception { > > ScriptEngine e = new ScriptEngin... System.out.println(((Invocable)e).invokeMethod(e.get("php.java.bridge.PhpProcedure"), "f", new Obje... > > On May 30, 2010 1:22 PM, <php...@li...> wrote: > > > Trying to c... |
From: <php...@li...> - 2010-05-30 18:33:44
|
Btw to avoid confusion: The engine key PhpProcedure is the environment that has been passed to the java continuation via java_context()->call(ENV) -- continuations are modeled as procedures, that's why it's called "PhpProcedure" On May 30, 2010 8:18 PM, "Jost Boekemeier" <jos...@go...> wrote: Hi, you are calling procedures from the servlet package outside of a servlet environment. I am surprised that this works at all. Outside of a servlet env use: import java.io.Closeable; import javax.script.Invocable; import javax.script.ScriptEngine; import javax.script.ScriptEngineManager; public class TestX { public static void main(String s[]) throws Exception { ScriptEngine e = new ScriptEngineManager().getEngineByName("php-invocable"); e.eval("<?php class X { public function f() {return 'hello';} } java_context()->call(java_closure(new X())); ?>"); System.out.println(((Invocable)e).invokeMethod(e.get("php.java.bridge.PhpProcedure"), "f", new Obje... > > On May 30, 2010 1:22 PM, <php...@li...> wrote: > > > Trying to c... |
From: <php...@li...> - 2010-05-30 18:19:07
|
Hi, you are calling procedures from the servlet package outside of a servlet environment. I am surprised that this works at all. Outside of a servlet env use: import java.io.Closeable; import javax.script.Invocable; import javax.script.ScriptEngine; import javax.script.ScriptEngineManager; public class TestX { public static void main(String s[]) throws Exception { ScriptEngine e = new ScriptEngineManager().getEngineByName("php-invocable"); e.eval("<?php class X { public function f() {return 'hello';} } java_context()->call(java_closure(new X())); ?>"); System.out.println(((Invocable)e).invokeMethod(e.get("php.java.bridge.PhpProcedure"), "f", new Object[]{})); ((Closeable)e).close(); } } On May 30, 2010 1:22 PM, <php...@li...> wrote: Trying to call a PHP script from a Java program. My Java program (Test.java) is this: ScriptEngine e = ( new ScriptEngineManager() ).getEngineByName( "php-invocable" ); e.eval( EngineFactory.createPhpScriptReader( "hello.php" ) ); System.out.println( ( ( Invocable)e ).invokeMethod( e.get( "php.java.bridge.PhpProcedure" ), "f", new Object[]{} ) ); ( (Closeable)e ).close(); The file hello.php is this: <?php require_once( "java/Java.inc" ); function f() { return java_server_name(); }; java_call_with_continuation( java_closure() );?> when I run from a terminal: java -cp .:./JavaBridge.jar:./php-script.jar:./php-servlet.jar:./java Test I get this: java.lang.NoSuchMethodException: f In my directory I have: hello.phpjava/Client.incGlobalRef.incJavaBridge.incJava.incJavaProxy.incJavaProxy.phpNativeParser.incOptions.incParser.incPHPDebugger.incPHPDebugger.phpProtocol.incSimpleParser.incJavaBridge.jarphp-script.jarphp-servlet.jarTest.class I'm running on Ubuntu 10.04 desktop (and also testing on 9.10 desktop). I installed PHP5 (php5-cli and php5-cgi) via the Ubuntu repository and had to modified /etc/php5/cgi/php.ini and changed "allow_url_include = On". Any ideas? Thanks, Bernard. _________________________________________________________________ New, Used, Demo, Dealer or Private? Find it at CarPoint.com.au http://clk.atdmt.com/NMN/go/206222968/direct/01/ ------------------------------------------------------------------------------ _______________________________________________ php-java-bridge-users mailing list php...@li... https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users |
From: <php...@li...> - 2010-05-30 11:22:29
|
Trying to call a PHP script from a Java program. My Java program (Test.java) is this: ScriptEngine e = ( new ScriptEngineManager() ).getEngineByName( "php-invocable" ); e.eval( EngineFactory.createPhpScriptReader( "hello.php" ) ); System.out.println( ( ( Invocable)e ).invokeMethod( e.get( "php.java.bridge.PhpProcedure" ), "f", new Object[]{} ) ); ( (Closeable)e ).close(); The file hello.php is this: <?php require_once( "java/Java.inc" ); function f() { return java_server_name(); }; java_call_with_continuation( java_closure() );?> when I run from a terminal: java -cp .:./JavaBridge.jar:./php-script.jar:./php-servlet.jar:./java Test I get this: java.lang.NoSuchMethodException: f In my directory I have: hello.phpjava/Client.incGlobalRef.incJavaBridge.incJava.incJavaProxy.incJavaProxy.phpNativeParser.incOptions.incParser.incPHPDebugger.incPHPDebugger.phpProtocol.incSimpleParser.incJavaBridge.jarphp-script.jarphp-servlet.jarTest.class I'm running on Ubuntu 10.04 desktop (and also testing on 9.10 desktop). I installed PHP5 (php5-cli and php5-cgi) via the Ubuntu repository and had to modified /etc/php5/cgi/php.ini and changed "allow_url_include = On". Any ideas? Thanks, Bernard. _________________________________________________________________ New, Used, Demo, Dealer or Private? Find it at CarPoint.com.au http://clk.atdmt.com/NMN/go/206222968/direct/01/ |
From: <php...@li...> - 2010-05-29 08:10:38
|
Hi, > if a user copies a library to java.ext.dirs and the library tries to access > javax/servlet, a NoClassDefFoundError is thrown. I think this is a misunderstanding. If users link their java applications according to the documents http://php-java-bridge.sourceforge.net/pjb/desktop-apps.php or http://php-java-bridge.sourceforge.net/pjb/webapp.php then they shouldn't get these link-time errors. Adding more information to the error message is not useful, users probably don't understand what it means anyway. But our FAQ should be cleaned up, of course. The sentence "All libraries and their dependencies must be loaded by one, and only one class loader." is obsolete, as we don't use a dynamic class loader anymore. Instead we should link directly to the above documents. Regards, Jost Bökemeier |
From: <php...@li...> - 2010-05-29 08:02:26
|
Hi Marta, I am currently preparing version 5.1.3 which will make it much easier to integrate custom php dll files (or 64bit binaries for that matter). > trying to connect via tcp://localhost:3306 Either it is not configured to listen on that tcp port or it is not running or the port is blocked. You can try to telnet to localhost 3306. Regards, Jost Bökemeier |
From: <php...@li...> - 2010-05-29 07:57:03
|
Hi, > thanks for your help, but my script does not contain ws =/ > what is JavaProxy.php? it's the file that is loading your PHP files (if you have option php_include_java set to "on" in your web.xml). > well, > I tried exportToXmlStream and it works fine. > just exportToPdfStream does not work because it is binary The JavaBridge.war from the documentation download contains a similar example which creates an excel file for download. Does it work? > Here two files to comparison > http://www.4shared.com/document/-23Wye9b/outputToFile.html > http://www.4shared.com/document/6LDWZ9Sy/outputToStream.html A "cmp" shows that these files are identical. Acrobat is able to read both of them. Can you please mail these files to jost.boekemeier at googlemail dot com? Regards, Jost Bökemeier |
From: <php...@li...> - 2010-05-28 16:38:02
|
I'm having issues with the java bridge installation on a 64bit server. Please help. I'm willing to pay for your time. Thanks, Jordan |
From: <php...@li...> - 2010-05-28 16:02:29
|
@Jost thanks for your help, but my script does not contain ws =/ what is JavaProxy.php? @ well, I tried exportToXmlStream and it works fine. just exportToPdfStream does not work because it is binary Here two files to comparison http://www.4shared.com/document/-23Wye9b/outputToFile.html http://www.4shared.com/document/6LDWZ9Sy/outputToStream.html 2010/5/28 <php...@li...> > Hi, > > your attachments did not come through. But such problems are usually > caused by a leading or trailing whitespace in the script generating > the output. Please check that your script does not contain any ws > before the <?php or after the ?>. We've had a similar bug in the file > "java/JavaProxy.php" between versions 6.0.0 and 6.1.2. > > Please see: > http://sourceforge.net/mailarchive/message.php?msg_id=l2k3afa16cf1004230903hfe3061cau42e1c00b64b28dd2%40mail.gmail.com > > > Regards, > Jost Bökemeier > > > ------------------------------------------------------------------------------ > > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users > |
From: <php...@li...> - 2010-05-28 14:55:00
|
Hi, Thanks for your reply. Doing what you suggested was definitely something I was considering but I'm stubborn so I couldn't leave my current problem alone until I fixed it. Fortunately I did and now everything's working smoothly. Sincerely, Marta Fernandes _________________________________________________________________ Hotmail: Trusted email with powerful SPAM protection. https://signup.live.com/signup.aspx?id=60969 |
From: <php...@li...> - 2010-05-28 14:49:34
|
Hi, I finally managed to solve this problem. I checked my script for leading or trailing whitespaces but there were none and then I accidentally came across this: http://www.php.net/manual/en/mysql.installation.php#96655 It turns out Jez300 was right. I managed to connect to MySQL as soon as I uncommented the line "127.0.0.1 localhost" in C:\Windows\System32\drivers\etc. I'd like to thank you for all your help. Sincerely, Marta Fernandes _________________________________________________________________ Hotmail: Powerful Free email with security by Microsoft. https://signup.live.com/signup.aspx?id=60969 |
From: <php...@li...> - 2010-05-28 10:18:33
|
Hello! if a user copies a library to java.ext.dirs and the library tries to access javax/servlet, a NoClassDefFoundError is thrown. The error message is: Unresolved external reference: java.lang.NoClassDefFoundError: javax/servlet/http/HttpServletResponse. -- Unable to call the method, see the README section "Java platform issues" for details and DO NOT REPORT THIS PROBLEM TO THE PHP/Java Bridge MAILING LIST! I think the error message should include the current class and its loader. Look here: http://forums.sun.com/thread.jspa?threadID=5440266&start=0&tstart=0 Peter |
From: <php...@li...> - 2010-05-28 07:43:41
|
Hi, your attachments did not come through. But such problems are usually caused by a leading or trailing whitespace in the script generating the output. Please check that your script does not contain any ws before the <?php or after the ?>. We've had a similar bug in the file "java/JavaProxy.php" between versions 6.0.0 and 6.1.2. Please see: http://sourceforge.net/mailarchive/message.php?msg_id=l2k3afa16cf1004230903hfe3061cau42e1c00b64b28dd2%40mail.gmail.com Regards, Jost Bökemeier |
From: <php...@li...> - 2010-05-28 06:01:07
|
I will be out of the office starting 05/26/2010 and will not return until 05/31/2010. I will be out of the office until May 3. I will respond to your message when I return. |
From: <php...@li...> - 2010-05-28 05:47:18
|
Hi, I used the command line you told me to. I appended the results to the text file attached to this email. The php_xxx.dll I have came with my PHP distribution so I suppose they're the same version. Thanks to you telling me to use that command line I realized I hadn't copied php-cgi.exe to WEB-INF/cgi as is stated in php-cgi-x86-windows.exe.MISSING.README (and as you mentioned in your second reply). Doing that solved part of my problem. My php scripts now work perfectly well under Tomcat, except for the ones that use MySQL. I don't know why but it takes too long to connect to the database. This time I'm getting the following error: HTTP Status 500 - type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception javax.servlet.ServletException: java.lang.RuntimeException: PHP Fatal error: Maximum execution time of 30 seconds exceeded in C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\pcmat\testWmysql.php on line 13 PHP Fatal error: Maximum execution time of 30 seconds exceeded in C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\pcmat\java\Java.inc on line 637 php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:1016) php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) javax.servlet.http.HttpServlet.service(HttpServlet.java:617) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) root cause java.lang.RuntimeException: PHP Fatal error: Maximum execution time of 30 seconds exceeded in C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\pcmat\testWmysql.php on line 13 PHP Fatal error: Maximum execution time of 30 seconds exceeded in C:\Program Files\Apache Software Foundation\Tomcat 6.0\webapps\pcmat\java\Java.inc on line 637 php.java.servlet.fastcgi.FastCGIServlet.parseBody(FastCGIServlet.java:923) php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:944) php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) javax.servlet.http.HttpServlet.service(HttpServlet.java:617) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) I don't think this is related to Tomcat or the PHP/Java Bridge because I copied the script to another location and tried running it from the command line. I got a very similar error: ****************************************************************** PHP Warning: mysql_connect(): [2002] A connection attempt failed because the co nnected party did not (trying to connect via tcp://localhost:3306) in C:\testWm ysql.php on line 12 Warning: mysql_connect(): [2002] A connection attempt failed because the connect ed party did not (trying to connect via tcp://localhost:3306) in C:\testWmysql. php on line 12 PHP Warning: mysql_connect(): A connection attempt failed because the connected party did not properly respond after a period of time, or established connectio n failed because connected host has failed to respond. in C:\testWmysql.php on line 12 Warning: mysql_connect(): A connection attempt failed because the connected part y did not properly respond after a period of time, or established connection fai led because connected host has failed to respond. in C:\testWmysql.php on line 12 Couldn't connect ****************************************************************** I'm just trying to run a simple connection test script (I made sure MySQL was running) so I don't know what's wrong. ******************************************************************** <?php $link = mysql_connect('localhost', 'mysql_user', 'mysql_password'); if (!$link) { die('Could not connect: ' . mysql_error()); } echo 'Connected successfully'; mysql_close($link); ?> ******************************************************** Any ideas? Sincerely, Marta Fernandes > Date: Thu, 27 May 2010 13:12:29 +0200 > To: php...@li... > From: php...@li... > Subject: Re: [Php-java-bridge-users] Getting MySQL to work with Tomcat and PHP > > Hi, > > the problem is always the same: user has copied php_xxx.dll version > /p/ into the ext dir which causes PHP version /q/ to crash. > > > > cgi\php-cgi.exe -c > > cgi\conf.d\mysql.ini -d > > extension_dir=cgi\ext -i > > It might make sense to create such a test script (Unix .sh or Windows > .bat file) in the WEB-INF/cgi folder and to refuse to start the > FastCGIServlet if the test script fails. > > Furthermore we should move the php_cgi.exe to WEB-INF/cgi/x86-windows, > WEB-INF/cgi/amd64-windows respectively. And the FastCGIServlet should > obey the "ProgramFiles" environment setting, which is not necessarily > set to c:\Program Files\ > > > Regards, > Jost Bökemeier > > ------------------------------------------------------------------------------ > > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users _________________________________________________________________ Hotmail: Powerful Free email with security by Microsoft. https://signup.live.com/signup.aspx?id=60969 |
From: <php...@li...> - 2010-05-27 21:12:55
|
Hi, I'm having trouble when I try to generate pdf by JasperReports using php-java-bridge. export to file works fine: $exportManager->exportReportToPdfFile($jasperPrint, $outputFileName); but export to stream to save on browser don't work: ---------------------------------------------- $javaOutputStream = new java("java.io.ByteArrayOutputStream"); $exportManager->exportReportToPdfStream($jasperPrint, $javaOutputStream); header('Cache-Control: '); header('Expires: '); header('Content-Transfer-Encoding: binary'); header('Content-Type: application/pdf'); header('Content-disposition: attachment; filename="output.pdf"'); print $javaOutputStream->toByteArray(); ---------------------------------------------- the file generated by the second option is almost equal to first option... but some binary data is broken on stream. I'm thinking that the binary data is broken because of the conversion between php and java. the two files are attached. Do vimdiff outputToFile.pdf outputToStream.pdf tks. |
From: <php...@li...> - 2010-05-27 11:12:36
|
Hi, the problem is always the same: user has copied php_xxx.dll version /p/ into the ext dir which causes PHP version /q/ to crash. > cgi\php-cgi.exe -c > cgi\conf.d\mysql.ini -d > extension_dir=cgi\ext -i It might make sense to create such a test script (Unix .sh or Windows .bat file) in the WEB-INF/cgi folder and to refuse to start the FastCGIServlet if the test script fails. Furthermore we should move the php_cgi.exe to WEB-INF/cgi/x86-windows, WEB-INF/cgi/amd64-windows respectively. And the FastCGIServlet should obey the "ProgramFiles" environment setting, which is not necessarily set to c:\Program Files\ Regards, Jost Bökemeier |
From: <php...@li...> - 2010-05-26 06:05:27
|
Hi Marta, php_mysql.dll needs mysql. Please use cgi\php-cgi.exe -c cgi\conf.d\mysql.ini -d extension_dir=cgi\ext -i to test ("x86-windows" omitted for clarity). If the above command line shows mysql in its output, the php demo files shipped with JavaBridge.war will be able to use mysql. However, I recommend to download php to c:\program files\php\ and use that for your tests. You can create your own demo (or product) using the JavaBridgeTemplate.war and your php download later. Regards, Jost Bökemeier 26. Mai 2010 4:46 vorm. schrieb am < php...@li...>: Hi! Thanks to the PHP/Java Bridge I managed to get my PHP applications running under Tomcat 6 (OS: Windows 7). The problem is, I can't seem to connect MySQL with PHP. I installed MySQL, added PHP's home directory and \ext directory to the PATH environment variable, and uncommented the extension lines for php_mysql.dll and php_mysqli.dll in php.ini. After doing that my PHP applications stopped working. I decided to comment the extension lines again and as soon as I did that my PHP applications started working again (but obviously I can't use MySQL). I did this a few times just to make sure the problem lied in those two extension lines. I keep getting the following error: HTTP Status 500 - type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception javax.servlet.ServletException: PHP FastCGI instance failed. php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:957) php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) javax.servlet.http.HttpServlet.service(HttpServlet.java:617) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) root cause php.java.servlet.fastcgi.ConnectionException php.java.servlet.fastcgi.FastCGIInputStream.read(FastCGIInputStream.java:52) php.java.servlet.fastcgi.FastCGIServlet.parseBody(FastCGIServlet.java:876) php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:944) php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) javax.servlet.http.HttpServlet.service(HttpServlet.java:617) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) root cause java.io.IOException: Protocol error php.java.servlet.fastcgi.FastCGIInputStream.doRead(FastCGIInputStream.java:61) php.java.servlet.fastcgi.FastCGIInputStream.read(FastCGIInputStream.java:48) php.java.servlet.fastcgi.FastCGIServlet.parseBody(FastCGIServlet.java:876) php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:944) php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) javax.servlet.http.HttpServlet.service(HttpServlet.java:617) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) If anyone could help me I'd be very thankful as I need Tomcat, PHP and MySQL working together in order to do my job. Sincerely, Marta Fernandes _________________________________________________________________ Hotmail: Free, trusted and rich email service. https://signup.live.com/signup.aspx?id=60969 ------------------------------------------------------------------------------ _______________________________________________ php-java-bridge-users mailing list php...@li... https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users |
From: <php...@li...> - 2010-05-26 03:52:08
|
Marta, I don't know if this will help but when I was setting up my PHP application I had similar issues when trying to use my usual MySQL/PHP routines and rather then play with the configuration I wrote this up: function get_users(){ //Get Use Table From MySQL //Setup Driver $drivermanager = new JavaClass('java.sql.DriverManager'); //Statement Holder $select1 = new JavaClass('java.sql.Statement'); //Result Holder $resultSet = new JavaClass('java.sql.ResultSet'); //Connect $conn1 = $drivermanager->getConnection("jdbc:mysql://localhost:3306/etc...") or die("Unable to connect to MySQL"); //Issue Command $select1 = $conn1->createStatement(); $resultSet = $select1->executeQUERY("SELECT * FROM u_data"); //Return Results return $resultSet; } ~Matt > > Hi! > > Thanks to the PHP/Java Bridge I managed to get my PHP > applications running under Tomcat 6 (OS: Windows 7). The problem is, I > can't seem to > connect MySQL with PHP. > I installed MySQL, added PHP's home directory and \ext directory to the > PATH environment variable, and uncommented the extension lines for > php_mysql.dll and > php_mysqli.dll in php.ini. After doing that my PHP applications stopped > working. I decided to comment the extension lines again and as soon as I > did that my PHP applications started working again (but obviously I > can't use MySQL). I did this a few times just to make sure the problem > lied in those two extension lines. > I keep getting the following > error: > > HTTP Status 500 - type > Exception report > message > description The > server encountered an internal error () that prevented it from > fulfilling this request. > exception > javax.servlet.ServletException: PHP FastCGI instance failed. > php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:957) > php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) > php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) > javax.servlet.http.HttpServlet.service(HttpServlet.java:617) > javax.servlet.http.HttpServlet.service(HttpServlet.java:717) > root > cause > php.java.servlet.fastcgi.ConnectionException > php.java.servlet.fastcgi.FastCGIInputStream.read(FastCGIInputStream.java:52) > php.java.servlet.fastcgi.FastCGIServlet.parseBody(FastCGIServlet.java:876) > php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:944) > php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) > php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) > javax.servlet.http.HttpServlet.service(HttpServlet.java:617) > javax.servlet.http.HttpServlet.service(HttpServlet.java:717) > root > cause > java.io.IOException: Protocol error > php.java.servlet.fastcgi.FastCGIInputStream.doRead(FastCGIInputStream.java:61) > php.java.servlet.fastcgi.FastCGIInputStream.read(FastCGIInputStream.java:48) > php.java.servlet.fastcgi.FastCGIServlet.parseBody(FastCGIServlet.java:876) > php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:944) > php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) > php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) > javax.servlet.http.HttpServlet.service(HttpServlet.java:617) > javax.servlet.http.HttpServlet.service(HttpServlet.java:717) > > > If anyone could help me I'd be very thankful as I need Tomcat, PHP and > MySQL working together in order to do my job. > > Sincerely, > > Marta Fernandes > _________________________________________________________________ > Hotmail: Free, trusted and rich email service. > https://signup.live.com/signup.aspx?id=60969 > ------------------------------------------------------------------------------ > > _______________________________________________ > php-java-bridge-users mailing list > php...@li... > https://lists.sourceforge.net/lists/listinfo/php-java-bridge-users > |
From: <php...@li...> - 2010-05-26 02:46:04
|
Hi! Thanks to the PHP/Java Bridge I managed to get my PHP applications running under Tomcat 6 (OS: Windows 7). The problem is, I can't seem to connect MySQL with PHP. I installed MySQL, added PHP's home directory and \ext directory to the PATH environment variable, and uncommented the extension lines for php_mysql.dll and php_mysqli.dll in php.ini. After doing that my PHP applications stopped working. I decided to comment the extension lines again and as soon as I did that my PHP applications started working again (but obviously I can't use MySQL). I did this a few times just to make sure the problem lied in those two extension lines. I keep getting the following error: HTTP Status 500 - type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception javax.servlet.ServletException: PHP FastCGI instance failed. php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:957) php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) javax.servlet.http.HttpServlet.service(HttpServlet.java:617) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) root cause php.java.servlet.fastcgi.ConnectionException php.java.servlet.fastcgi.FastCGIInputStream.read(FastCGIInputStream.java:52) php.java.servlet.fastcgi.FastCGIServlet.parseBody(FastCGIServlet.java:876) php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:944) php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) javax.servlet.http.HttpServlet.service(HttpServlet.java:617) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) root cause java.io.IOException: Protocol error php.java.servlet.fastcgi.FastCGIInputStream.doRead(FastCGIInputStream.java:61) php.java.servlet.fastcgi.FastCGIInputStream.read(FastCGIInputStream.java:48) php.java.servlet.fastcgi.FastCGIServlet.parseBody(FastCGIServlet.java:876) php.java.servlet.fastcgi.FastCGIServlet.execute(FastCGIServlet.java:944) php.java.servlet.fastcgi.FastCGIServlet.handle(FastCGIServlet.java:991) php.java.servlet.fastcgi.FastCGIServlet.doGet(FastCGIServlet.java:1040) javax.servlet.http.HttpServlet.service(HttpServlet.java:617) javax.servlet.http.HttpServlet.service(HttpServlet.java:717) If anyone could help me I'd be very thankful as I need Tomcat, PHP and MySQL working together in order to do my job. Sincerely, Marta Fernandes _________________________________________________________________ Hotmail: Free, trusted and rich email service. https://signup.live.com/signup.aspx?id=60969 |