» If you review the Intro to PHP at w3schools, you'll find Javascript listed as one of the items there under the heading » What You Should Already Know. That's interesting .. cuz you dont need to know Javascript in order to learn PHP.
I know .. cuz I've been learning PHP, and I dont know JavaScript. (Rather, I know about JavaScript .. specifically its dot.syntax - from general.to.specific)
[ Note the converse is not true. PHP is not listed as a prerequisite for learning JavaScript. (Only item listed is HTML. Heck, not even CSS.) ]
PHP code is executed on the web server. JavaScript, on the other hand, is executed on your local machine (.. in your browser). Two totally different environments.
Most web people, I'd imagine, learn Javascript (browser scripting) before they learn PHP (server-side scripting).
This seems to be the natural progression of things. In other words » first HTML (page structure & conent) » then CSS (presentation & styling) » JavaScript (behavior) » PHP/MySQL (server-side mojo).
» HTML5 Makes This a Good Time
Recently I've been learning HTML5. The longer I look, the bigger HTML5 seems. From what I can see, it promises to be a major step forward for the Web.
The main reason for its geeky coolness (by far) is the new HTML5 API's. (I count 31 of them.) As Erik says, HTML5 means » more power to the browser as a programming platform.
And the language HTML5 uses to exercise this power? .. that's right » JavaScript.
In HTML 4, for example, you need to specify JavaScript as the language inside the script tag (i.e. » <script type="text/javascript">
). In HTML 5, on the other hand, you neednt specify (rather merely » <script>
) .. cuz JavaScript is assumed (.. as the default scripting language for an HTML5 web page).
So it's clear, even from my limited vantage point .. as a non-professional web-hacker .. that the time for learning JavaScript has arrived.