分享 关于 PHP 社区的那些事。。。

fredwu · June 30, 2012 · Last by leozwa replied at July 01, 2012 · 5275 hits

昨晚(其实是凌晨四五点的时候),写了篇博文。

在 Hacker News 上重新提交了一下,大家帮忙来投一票吧,谢谢哈 http://news.ycombinator.com/item?id=4180548

附贴全文:


TL;DR - PHP is still a useful tool, but as a PHP developer, have you started playing with other useful tools? Here's my story.

Today Jeff Atwood's new piece "The PHP Singularity" and Marco Arment's "PHP Addiction" have started another round of heated discussion on PHP.

As someone who started his career as a PHP developer, I feel like sharing my thoughts from a different perspective.

I began my career as a freelancer - since JavaScript and PHP were the two programming languages I learnt at school, they naturally became my weapon of choice for freelancing work.

At that time I knew very little about software development. My desire was simple: I liked making websites, therefore I decided I was going to do it for a living.

Over the years I came across many people who shared a similar background - people who do not have a strong (or any) computer science / software engineering background, were making websites.

Compared to most software developers, the intention of doing programming for me was different. I had no intention (or awareness) to create maintainable software, instead I simply wanted to create an end product that works.

Was I wrong? According to the market, no. There are many clients who want affordable websites, just like there are many people who want affordable Android phones. On one end you have Android phones that compete with the iPhone and take time to get released, on the other end you have Android phones that use readily available, often less desirable components and are quick to market. Each serves its purpose and fulfils customer demands.

As I kept developing websites and educating myself, I became more and more interested in software development. That's when I started reading books like "PHP Objects, Patterns, and Practice". But even then, my knowledge was still extremely limited, and my desire at that time was to increase my PHP knowledge and become a better developer.

For the first desire I made it happen by reading more books and articles, but for the second desire - I thought I made it happen, but in reality I didn't because I did not correctly identify my weakness. It wasn't just about the depth of knowledge, but also the breadth.

Spending most of my time writing PHP made me too comfortable in a little corner. The discovery of tools such as CodeIgniter made me feel good about being a competent web developer. After all, I was doing quite a fine job churning out websites.

In 2006 I discovered Ruby on Rails, but that did not have too much impact on me, because I was not yet capable to tell the differences it has compared to PHP (frameworks).

In my mind, PHP and Ruby are both scripting languages that can be used for developing websites and web applications. Although the statement is true, not knowing the specifics made me very ignorant. It is almost like not knowing the difference between travelling from one continent to another by an airplane and by a ship - either will get you to the destination, right?

And this is exactly why my first ruby program looked just like a PHP program.

It was (and still is) an interesting and rewarding journey to slowly discover why my Ruby code sucked.

So I started reading on design patterns, software craftsmanship and other programming languages. And I was lucky enough to be surrounded by many brilliant developers who taught me how to write better code.

At that point, my intention for learning more about software development had shifted from simply making an end product, to making an end product that can be maintained.

And that changed everything. From a PHP developer who just wanted to churn out websites quickly, to a developer who wanted to use software development to create value - in the sense of both business value and technical value.

An important thing to remember is though, it's not about Ruby, and it certainly is not about looking down on PHP. Rather, the point is to see whether or not there's something out there that might enable you to look at things differently, and do things differently, for better or for worse.

PHP for some is a double-clawed hammer, but there is no doubt in my mind that for some others it is a near perfect tool, for now at least. Having said that, many other kids have started playing with all sorts of toys, why haven't you? :)

再翻译一下,哈哈

You need to Sign in before reply, if you don't have an account, please Sign up first.