Pregunta

  • I know a little java, android languages.
  • Now I want to build an Android server-client application and for client side I will use Android(java) and for server side either JSP/servlet or PHP.

So I have 2 questions:

  1. What is easier and faster to learn PHP or JSP/servlet(also don't forget that I also know java) ?
  2. 2)Which one would work better? as the client side would be written in Android(java) may be the JSP/servlet would work better, or it doesn't matter?, and as PHP is the most used server language may be it would work better?

Thank you in advance.

¿Fue útil?

Solución

  1. I personally found PHP simpler and easier to learn, BUT i knew JAVA and C++ before. I would also like to add that a few of my colleagues that had little experience with other programming languages found PHP to be fun and easy to learn. You have much less to worry about memeomry consumption, variables types, Threads etc...

  2. It totally depends on what your system will require.

-Java is more complex and thus offers a wider range of possibilities, more control etc...

It doesnt mater in what programming language the client application is written in, since client/server communication is done using "standard protocols and systems and formats", such as REST protocol, JSON data encoding and so on....

Another advantage of PHP is that it will run on basically any hosting you purchase for your server, since most of them if not all support PHP/mySQL, while Java will probably require you to purchase a Cloud service or something similar. In such sense PHP may come cheaper to you.

I would also like to add that i have used PHP in most server apps i made, one example was a trading app...but some apps that needed multithreading + RAM caching + hash maps + sockets + other Java functionalities that are built in, etc were meant for Java...so PHP can do the work, but for some things Java is better and just comes naturally...this is totally based on my personal experience so dont take it for granted, you may have a totally different experience.

Maybe tell us what will your app do so we could point you in the right direction.

This

Licenciado bajo: CC-BY-SA con atribución
No afiliado a StackOverflow
scroll top