Live data from Hacker News

Ask HN: Please tell us how you started a project in PHP and are sorry for this.

news.ycombinator.com

1–10 of 36 posts

Ask HN: Please tell us how you started a project in PHP and are sorry for this.

#1
And if you have to start the same project again what would be different and why?

I've invested over 10000 hours in PHP and I want to know whether to invest another 10000 in some other language and what are the alternatives.

There are lot of opinions in the wild but I think that opinion supported by example is much better than just "I like X and dislike Y"

edit - some grammar EDIT 2 - To be more precise - I am not looking for a brain teaser, but for a tool which will allow me to be 1.5x (or 2x or 3x) more productive. I am looking for a tool to feed my family and myself in the next few years. To be honest I am a little scared of all "PHP sucks" articles. I don't want to be jobless in 3 years when/if PHP becomes the new COBOL.

Re: Ask HN: Please tell us how you started a project in PHP and are sorry for this.

#2
I'd like to say something, stick to PHP. PHP is a very neat programming language; I recommend you to read about Composer and PSR standards, but if you want to learn something different, try with Python or Ruby, both languages are kind of similar, hope it helps.

Re: Ask HN: Please tell us how you started a project in PHP and are sorry for this.

#3
IMO - if you are starting a project as a business, go with what you or your developers are most comfortable with. If for some reason you need to change down the road then so be it. There are plenty of sites that are highly successful that have been built on PHP.

On the other hand, if you are building a project to learn from, or for personal reasons, then take the time to start learning a new language.

This is not to say you can't invest time in another language to build a project in a different language. There may be reasons where PHP will just not cut it.

So to answer your original question. There are no projects I am sorry for building in PHP. However, there are projects where I look back and say I wish I had taken the time to learn a different language. Those projects tend to fall into the second category and I was just too lazy to take the time to learn something new/different at the time.

Re: Ask HN: Please tell us how you started a project in PHP and are sorry for this.

#4
I've done some dreadful things in PHP. And Java. And Python. And C. And more..

The problem has never been the language, but rather the software's organization and architecture (or the lack thereof). You can make mistakes in any language, some just make it a little easier for you. Such as PHP's notorious ability to mix code and HTML in the same file... the horror!

Before contemplating a language change, you might want to think about ways you could improve your architecture, development practices, and code hygiene.

Re: Ask HN: Please tell us how you started a project in PHP and are sorry for this.

#5
As a PHP dev (8 years), I can honestly say PHP is an ugly language. But it gets the job done. And I'd say with 10K hours under your belt, you can do what you damn well please. Feel like spending another 10K hours in PHP? Go for it. Wanna learn C or Rust or Scala or Python or Ruby? Knock yourself out.

I personally am a fan of diversity (master one skill set, then another, then another). Unless you're doing cutting-edge work, you're probably at that point where your diminishing returns are close to zero, so you might as well learn something new.

Re: Ask HN: Please tell us how you started a project in PHP and are sorry for this.

#7
I spent a few years freelancing as a PHP developer and then transitioned into python for the last 3. It's fairly easy to transition between PHP/Python/Ruby and I'd suggest getting a little bit familiar with similar languages. I know that knowing a bit of all three has led me to be able to develop more quickly and cleanly. Also, more diversity in your understanding would help with your job security concerns.
Post reply on HN