📜 ⬆️ ⬇️

PHP: programming culture

When it is not


Low threshold of entry, easy way to shoot yourself in the foot, spend your energy learning a real programming language - a PHP developer from fellow programmers who are fortunate enough to learn other technologies can hear a lot of hurtful words. PHP is convenient to blame everyone - every initiate can find what to cling to. Nevertheless, good specialists are still in great demand on the market who are able to write high-quality code in this language. Moreover, if you chose this path, in an interview in a serious company with technically-savvy managers and senior programmers, you are unlikely to hear anything mocking about PHP.

In many ways, this negative attitude is due to the lack of programming culture in a large number of PHP developers. Why it happens? Yes, this language has a really low threshold of entry and a person without special technical education can easily master it. Having studied the basics, you can immediately make small projects and even sell your services on the freelancer exchanges. And if there is a demand for this, why waste time on deepening your knowledge, when you can earn money now?

Sometimes a miracle happens - such projects are "taking off" and their owners need to expand the functionality and increase productivity, and the connection with the person who made all this a year ago, has, alas, been broken. Yes, and the owners have the money to pay for these professionals.

And then a specialist comes to support all this heritage, clones the repository (at best, it happens that they have not heard about version control) and slowly begins to turn gray with horror. Colleagues smirk - “Oh, yes, it's PHP! What did you want? What is the language, so is the code. ” And yet, if the project through some API needs to interact with other parts of the branched system, then all the technical specialists in the organization start cursing the “picker” who created it. If you are a beginner PHP developer and you are not a fan of humiliation, pain and all that other stuff, try to share with you a positive experience.
')

Be more cultured


We can talk about a common culture when there is a set of symbols, codes that unites us. Software developers have such spiritual skr such a special language of communication, the level of understanding of which makes it possible to recognize a good specialist. Fortunately, this is not some secret writing of the initiates - be curious and this knowledge will definitely come!

For example, I myself began to develop in PHP, when a wild mix of HTML code with logic and many entry points did not seem to be something terrible. I was an absolutely uncultured programmer, I didn’t have a technical education, I knew about the language from the forums and the book by Luke Welling and Laura Thomson “Developing Web Applications Using PHP and MySQL”, but this state of affairs gave a lot of pain. I have not even heard of such a term “entry point”. The thought came - how to send all requests to only one script and process them centrally? Curiosity forced to learn the configuration of Apache and the possibilities. Htaccess.

Then he realized that investing in his own knowledge always pays off many times, is a win-win. And the programming culture is based on knowledge (but not only), and this is the main value in the developer community.

Culture is text


I met programmers who did not like to read technical literature. Not to say that they were bad experts in their field. Most often, when asked why you don’t know this author or how you could miss the second edition, there’s just what you’re working on answer: why spend long hours reading water flows, when knowledge can be obtained in compressed and convenient form of documentation and something like stackoverflow. Of course, during the conversation, it often turned out that this is a little slyness, in the cultural baggage there is already a Gang of Four, both the “Perfect Code” and the “Programmer-Pragmatist” ... We understand each other.

Now serious bearded apologists for Java and C ++ will ask the question - what does all this have to do with PHP? Do not throw me spoiled vegetables - PHP can also write beautiful things, unless, of course, there is a deep understanding of how to do it. And it is impossible without a wide context of programming culture. To see the beauty of the language, to understand how to do it right, I was helped by the book by Matt Zandstra “PHP. Objects, patterns and programming techniques. After the first reading, many things were incomprehensible, but there was an overwhelming desire to absorb technical texts in megabytes.

And later it became clear that you can know a good programming language if you know other languages. To get a good theoretical basis in this regard, I was first helped by the book by Bjarne Stroustrup “Programming: principles and practice of using C ++” (in general, her reading once suggested me thinking about writing an article about programming culture and PHP). And it is not necessary to sharpen their abilities in another language to perfection (although, most likely, one of these will ultimately bring more joy than PHP), it is enough to understand the principles and differences. Such a versatile view opens up previously hidden opportunities to make your code clearer and more productive, and seeing familiar design patterns in your source code, the Java gurus will no longer look at you (well, maybe a little bit out of habit).

Source: https://habr.com/ru/post/267727/


All Articles