Does php and javascript pretty much have the same features? What's better?
PHP is far superior to javascript. Javascript shouldn't be used at all, IMHO.
Javascript is a plugin. Which means not everyone can use it.
PHP is a server-side language. Which means it runs on the server and not the users computer. Which means it works for everyone.
To use PHP you need to have it installed on your server though. It goes very well with MySQL. Which also needs to be installed on your server.
The only use javascript has is button-rollovers, window sizing, etc. Cosmetic stuff, which you can use CSS for a lot of the stuff.