I've been considering the same thing but for a Scorched Earth/Gunbound style game.
To make the kind of game you are talking about there are going to be two parts:
- The client side (player's browser)
- The server side (your game's server). This encompasses:
- The language used on the server
- The database used to store data
For the client side your two options are pretty much (in no particular order):
- Actionscript (Flash)
For server side languages (again, no specific order):
- PHP (see Lohoris's answer)
- Java (sorry don't really have a link, but you mentioned you are familiar with it)
For databases (no specific order):
- MongoDB (this is a NoSQL database)
The server side can be pretty much whatever the heck you want it to be. You'll likely want support for sockets which PHP and node.js support, making them viable options. Your question mentioned you are familiar with Java and that's a viable option as well. If you're comfortable with Java (and not doing this to learn new languages/technologies) that's may be your best bet.
As far as databases go MySQL and Postgresql are widely supported and established databases. Something like MongoDB is a bit more exotic and may not be supported by your server side language of choice. Me, I'd probably use Postgresql unless I was interested in mucking around with NoSQL or thought it gave some clear, tangible benefit.
Does Your Game Need To Use Sockets?
To me this then becomes one of two questions:
- Which technology do I want/need to use server side? Or,
- Which technology do I want/need to use client side?
If I needed binary sockets or wanted to use Java on the server I'd probably choose Flash on the client side. There are a lot of socket servers written in Java for the express purpose of supporting multiplayer Flash games (SmartFox is one example).
** Via WebSockets in most modern browsers.
Can You Get By With Remote Procedure Calls Instead of Sockets?
If you can use RPC (think AJAX) then you're really free to do things however you see fit. Just about any browser (even the shambling corpse that is IE6) supports AJAX calls, as does Flash. Likewise any server technology is going to be able to respond this these requests. If your design allows for this it really becomes a matter of which technologies you prefer.
What Languages Are Supported By Third Party Solutions
If you'll be integrating with third parties you should check out what technologies they support. While there is no reason you cannot run the game server in Java and integrate with your payment gateway in PHP but it would probably be easier to just have it all be in one or the other.