Just to clarify:
PHP: Server side scripting language.
JavaScript: Client side scripting language.
JavaScript can be used for interacting with a webserver without having to reload the webpage
(see AJAX), which is a very useful technique ,however it requires a PHP (or some other server side program) to do the actual server side stuff.
JavaScript can be used to say enable/disable a button depending on what is entered into a text field, which is fine, but you
NEED server-side code to check if the filtering did occur, since otherwise a hacker can simply stop the JavaScript from running, as it runs in his own browser.
You should use them both, at the same time. There is no point in designing a website with only PHP to begin with, even though it is easier, because when it comes to adding JavaScript and AJAX functionality to it, it is going to be so much harder.
So unless you can clearly say, that you won't need one of them for a project, then use both.
When it comes to which one to learn first, then I learned JavaScript first, but you could probably just as easily start with PHP.
It really depends.
(12-23-2012, 09:28 AM)davis60 Wrote: I am not a devloper, but according to my knowledge you should learn Javascript first (easier than PHP actually)
That is really a matter of taste.
I personally found PHP easier to learn, because it is completely straight forward. JavaScript has some mean tricks here and there.
The only hard thing with PHP is when you want it to use it in conjunction with JavaScript (AJAX), but that also requires you to use JavaScript which in this case is about the same difficulty as the PHP.