0

I want to create an application that submits same/similar data to sites containing web forms. These sites use PHP scripts...

I have a php script with me, that submits data in the manner that i require, to such forms. What I want to do is, design an entire web app around this code... I tried to obtain equivalent java code that does what the php code is doing, but could not obtain such code...

Since Google App Engine supports Quercus framework for PHP, what I am thinking now is, use the PHP code for actual submission of forms to their actions, and rest of application (that tracks all submissions and does other stuff like login/logout...) is in Java.

This would require some method by which I can pass the relevant form parameters from Java code to the PHP script, then some way for the php script to return the response of each submission back to the java code.

Is such an application doable? Pls keep in mind that I want to use Google App Engine for this purpose.

user893664
  • 319
  • 1
  • 9
  • 23
  • 1
    but why you could not obtain such code? – Igor Artamonov Aug 25 '11 at 16:54
  • I think solving your original problem is a better solution than trying to run the original PHP code. If you don't fully understand how the PHP code works, you're not going to be able to maintain it. – Nick Johnson Aug 25 '11 at 23:40
  • @splix, i am trying to do it on google app engine... but i may not be successful due to some limitations of app engine itself (eg persistent http connections are not permitted on app engine)... @ Nick- I do understand how the php code works, but i cannot find an equivalent class that implements the same functionality in java... – user893664 Aug 26 '11 at 11:53
  • So, if it have limitation for java, why you sure that it haven't same limitation for PHP???? – Igor Artamonov Aug 26 '11 at 12:12
  • i have working php code that does what I require... however I am unable to do the same thing in Java... thats why now I am thinking of having a hybrid app (because GAE does support PHP indirectly...)...the php code uses curl, and i could not find any docs/javadocs for libcurl which is the equivalent of curl in java... and other classes dont do the work done by the php code... – user893664 Aug 26 '11 at 12:22

2 Answers2

0

Nowadays it is possible to use different languages in different modules of the same app.

See Using both Java and Python with the new "Module" feature on AppEngine?

Community
  • 1
  • 1
Dan Cornilescu
  • 39,470
  • 12
  • 57
  • 97
0

It should be doable with Quercus. We deploy a Python app that has some Java/Clojure backend processors but both languages are "native" to GAE. Using PHP will be a serious pain and not worth it all. I suggest that you just learn Python you will master it faster than using Quercus on GAE.

If you also go after PHP you stick to your LAMP knowledge. I suggest thay you do now!

Disclaimer: I wanted to use JRuby on AppEngine but I had a lot of difficulties (plus you have to know how everything works optimally on GAE) so I took up Python

Robert Levy
  • 28,747
  • 6
  • 62
  • 94
PanosJee
  • 3,866
  • 6
  • 36
  • 49