Firstly geocities doesnt have PHP installed, unless its something that has just come up very recently.
Secondly to use PHP it firstly must be installed on a server, secondly there must be a web server that can recognise a .php file to be intepretted by the php engine.
Now to get this working online you must find a host that supports PHP. There are not many free PHP hosts around anymore so you may wish to get paid hosting.
If you want to do testing on your home computer you will also need a webserver + php installed. This stickied thread has a installation tutorial http://phpbuilder.com/board/showthread.php?s=&threadid=10245251.
If you do not feel comfortable with that there are a few pre-packaged solutions. Which you can do a search for.