Could this be done with a database, php and ajax?
Something like (thinking out loud here).
Database Table:
Player 1
Player 2
PlayersTurn
GameString
In your game.
Player 1 playing his game.
Game checks database for PlayersTurn data. If 1, game continues.
Player 1 plays.
Turn over, send data to database setting PlayerTurn = 2 and GameString to whatever data you need to send for the other player.
I'd be happy to do a tutorial on it if you think it would be useful.