PHP or JavaScript?

It depends on what you what. JavaScript is the language of the web. It is the only choice for front end development. JavaScript is usually client-side where PHP is server-side.

JavaScript is extremely versatile for front end development. Although lately a lot of what needed JavaScript in the past or jQuery to be done can now be accomplished with CSS (for presentation).

Wordpress is built on PHP along with a ton of other great sites. PHP has it limitations and its strengths as a backend language, but mixed with the right framework you can accomplish anything. Where the choice lays is to use Ruby, Python or PHP. They are all fantastic and have great communities it just depends on what you want to build!