Java is more powerful as compared to PHP; java can be used for the development of the large enterprise level applications, in java we can use large number of application.
PHP is used for small scale applications. Java is more secure as compared to PHP.