

Ask HN: What web based language should we learn nowadays? - user48

Hey,
I am currently studying applied computer science (B.Sc.). Before this I've done a school job training which was in a very similiar field, but broader and obviously not as deep.
During my job training and also now at university we're getting taught about web programming. Both times with PHP as the server side scripting language.
Now, the other day I've got an invite from koding.com (I've signed up for their beta when it was posted on HN a while ago) and in the feed for latest messages I found a commenter saying that PHP is old and should be abandoned.<p>I will have to get deeper into PHP now anyway, as I obviously want to pass the semester with a good grade, but:<p>Should PHP actually be replaced entirely?
Also, which language would be useful to learn for the future?
======
lsiebert
Php is still used and developed. Perl is still used and actively developed
(both 5, which is the stable version with backports occasionally, and 6 which
is a complete rewrite, but still very much in development).

You can get a job as a php coder. Plenty of companies use it.

People like to give their first languages love, and lots of people learned to
program in something like ruby or python, so they keep programming in them.
But that doesn't mean that older languages or legacy code go away.

That doesn't mean you should stop learning. Learning more than one language or
framework can help you become a better programmer. But don't let people tell
you php is over.

There are languages that are pretty much gone, except for legacy code.
Practically nobody learns pascal anymore, from what I can tell.

Php, however has held up surprisingly well, compared to a lot of
languages/frameworks. You might try picking up another language, like java
script.

------
saiko-chriskun
The four big web languages off the top of my head today would be: php, ruby,
python, and javascript. You still see java in parts, or other jvm-based
languages such as scala.

Personally I wouldn't worry much about which language you should learn. A lot
of skill in programming and development is being able to conceptualize
abstract problems, and learn new things on the go. I actually promote learning
languages like haskell because, although you'll rarely use it professionally,
it gets you thinking about things in different ways and, in turn, makes you a
better programmer.

Just learn what you want for now (php?), and when you need or want to expand
in the future, do so :).

~~~
rudimk
I'd go with you. Just go with PHP for now, and once you feel you've got a good
grasp of it, go in for Ruby or Python, as well as Javascript and a functional
language like Haskell - Clojure's a great bet too.

------
memracom
There is only one web-based language and that is Javascript. With node.js and
Rhino, it can now also be used on the server side.

So if you really want to learn a web-based language Javascript is the one. If
you decide to go for Python or Ruby (good choices) or even PHP or PERL (bad
choices) you still can't escape from learning and using Javascript.

Personally, I think that you should pick Python or Ruby, whichever seems to
suit you, since both are solid languages that are widely used to build web
apps and lots of other stuff. PHP and PERL are yesterday's languages and are
fading away slowly but surely.

~~~
user48
well, I won't get around PHP as I have to use it for university. It seems
you're having the same opinion as the person that brought me to ask this
question. He said PHP was a dinosaur that we should get rid off.

According to most replies on here it rather seems that it's very useful and
recommended to still know that language as it's still widely used.

I will, however, take a look into JavaScript (already started with codecademy)
and later on at the other suggested languages.

Rhino is so far the only one I haven't previously heard about.

Thanks for your replies.

~~~
Mithaldu
Please disregard the comments about Perl made by the person you replied to. He
knows very little about it. Perl is still a very strong language that has not
been overtaken by Python or Ruby in the job market:
[http://www.indeed.com/jobtrends?q=perl%2C+python%2C+ruby%2C+...](http://www.indeed.com/jobtrends?q=perl%2C+python%2C+ruby%2C+rhino%2C+javascript%2C+php%2C+node&l=)

If you do look into Perl, start on this site: <http://perl-tutorial.org> It
will show you the most up-to-date learning resources for Perl.

About PHP, give this blog post a read:
[http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-
de...](http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design/) It
makes the point that while you can develop and deploy very quickly with PHP,
you will make trade-offs and will have to sacrifice consistency and
predictability.

Lastly, as a general advice: Look at all the languages, figure out which ones
are fun for you and learn those. I say those because you will need to learn
more than one. :)

~~~
user48
thanks for the links. I will definitely take a look at several languages and
learn more of them over time.

------
curiouslearn
I think Python would be a very good choice. With it you will be able to do a
lot more than programming web applications. For example, it has excellent
libraries for scientific work. At the same time, it is very good for creating
web applications (although probably not so much for real time web-
applications, but I doubt Php is very good for that either). It has many very
good web frameworks. I have used web2py, which makes it easy to create
websites, and equally important, to deploy websites on various PAAS platforms.

------
lazylodr
I started with PHP and ran with it for several years. It was my entry language
for web development. Currently I'm using Ruby almost exclusively. Each has
their strengths, but after spending a lot of time in Ruby, it's difficult to
enjoy writing code in PHP. Ruby was deigned with developer happiness in mind,
after all.

For me, the most interesting thing about programming are language agnostic
principles and design. Learning the fundamentals will translate to any
language.

------
canatan01
Besides PHP, I would go for Python. Many startups ask for Python coders, so
that would be handy. As for PHP: many big websites still use it (FB) and PHP
is still being developed. And some say that PHP is made fun again because of
the framework Laravel.

------
chris_dcosta
I think I should add that it's not just about the language, it's also about
the architecture. You need to know what's going on and where, and why.

------
anonfunction
Javascript! It's the future. Learn basic client side JS and then move onto
node or vice versa.

~~~
chris_dcosta
Seconded. Have you seen the freelance rates?

