One thing to keep in mind is that PHP excels at several things. Among these are: 1) string handling; 2) array handling; 3) regular expressions. PHP gives you an incredibly rich feature set of functions and capabilities without having the need to enlist a particular package, module, or custom tag. Array handling is a thing of beauty - in Java you will write much more code to manipulate arrays. Regular expressions - for searching, replacing, and parsing strings - are very strong in PHP and weak in Java.
In harvesting dynamic information from the web, often times we spend a lot of time gathering form variables, parsing them, and validating them. A lot of what we do is routine. If you are doing a lot of that, PHP has a lot of what you need and you may not need the elephant gun power of Java.
Java's object-oriented capabilities far outdistance PHP. Which is not to say you can't do a few cool OOP things with PHP, however. But if you need more scalability, and you will be working a lot with distributed objects (CORBA etc.) or similar architectures, Java may be the right choice.
PHP, unlike Java, does not straightjacket you into the OOP paradigm. With PHP you have a choice. Sometimes the good-old procedural-passing-data-into-and-out-of functions approach is the fastest and most efficient way to build an application. If you're scaling for a lot of future expansion and are modeling a lot of objects, then Java might be a better choice.
PHP, unlike Java, is weakly typed. I've found this to be more of a blessing than a curse. That's because the PHP/Zend engine is so great at catching most of your errors anyway. I'm sure many would disagree, and prefer the strongly typed capabilities of Java.
Whatever you choose, good luck and I wish you success in your development outcomes!