Is PHP a dying language?

移动用户-8334543
Release: 2023-03-16 11:52:01
Original
1278 people have browsed it

It seems like this question gets asked every year because for some reason people's perception of PHP is that it's a language used by amateurs, or it's a dying language - one that's dying programming language.

Before we look at “Is PHP getting less and less used?”, let’s start with some key points to consider when choosing a programming language to learn/invest in.

PHP powers about 80% of the web

The first point is how popular PHP is as a programming language. A debate was raised recently on a blog about PHP, the issue being that it is an "enterprise" language. The argument against PHP is that it has not been widely adopted in enterprise application development or applications traditionally developed in Java or .Net.

The key here is to understand that each tool has its advantages and disadvantages, and sometimes it is smarter to use a compiled language like Java instead of PHP. As always, you want to choose the right tool for the job, and PHP excels as a programming language in web applications. That’s why today it powers nearly 80% of the websites on the internet! I would like to repeat this number, almost 80% of the websites on the internet!

In the blog, after the initial argument that PHP is not an enterprise language, I have a question to ask - "Can you name an enterprise that does not use PHP?" Despite the misconception that PHP is not an enterprise language The language of enterprise, but almost every enterprise uses PHP in some way (many for their websites, blogs, or internal tools). While PHP may not power the applications they offer as a service (although for many companies it does), it provides equally important support for the products that help drive a company's success.

This isn't just a personal blog running on a WordPress installation, or a small website running on Drupal (both of which are high-traffic, well-known web properties, by the way), but PHP actually Make web development easier and faster. Because it's not a compiled language and is designed to scale, companies are able to launch faster, add new features, and grow to massive scale.

Some websites developed in PHP include Baidu, Facebook, Sina, but it’s not just old platforms starting to use PHP and expanding with the development of PHP - Etsy, Slack, Box and Canva are also starting to use PHP! Read why Slack chose PHP

In fact, according to BuiltWith, PHP powers 53.22% of the top 10k websites!

Programming languages ​​don’t just disappear

Understanding how popular PHP is today and how often it is used is crucial to understanding PHP’s longevity. Despite radical ideas, programming languages ​​(and programming jobs) won't disappear overnight. Today, you can still find work writing code used in mainframes—for example, Fortran or Cobol.

As long as a company has an application that uses PHP, they will need someone who knows PHP to maintain the application. With PHP being actively developed and maintained (PHP 8 just released), and with PHP powerhouses like WordPress, Drupal, SugarCRM, and others powering websites and applications around the world, it's a safe bet that PHP isn't coming anytime soon Anywhere.

But, with the basics out of the way, let's see how PHP has evolved over the years.

PHP Usage Over the Years

While there is no exact metric to determine how programming languages ​​are ranked, we can get an idea of ​​how a programming language is ranked by looking at a few different rankings. How the language has evolved over the years and where it ranks today.

GitHub's Most Popular Programming Languages

Every year GitHub releases a report on the most popular languages ​​used to create repositories on GitHub.com. While this is not an accurate way to quantify programming languages, it does help us understand which languages ​​developers are using and promoting for their applications. It also helps us understand how active the community itself is.

In 2014, PHP was ranked as the third most popular programming language, behind JavaScript and Java. With the advent of Typescript, C# mobile open source, and the increased use of Python for AI - PHP has indeed declined - and was the 6th most popular programming language on GitHub in 2020.

PHP on GitHub over the years

PHP’s ranking on the Tiobe Index

Another index of software popularity is the Tiobe Index, which is based on The number of programming languages ​​search engines rate them. Companies rely heavily on the index when making programming and investment decisions, especially when it comes to developer marketing.

Like GitHub, PHP's Tiobe Index has also declined. Ranked 8th among all languages ​​last year, PHP dropped to 9th, surpassed by C (C, C#, C), Java, Visual Basic, Python, JavaScript, and Assembly. However, to compare rankings, PHP ranks 9th out of 274 languages ​​tracked by Tiobe and outperforms SQL, Ruby, Groovy, Go, and Swift.

PHP Ranking on BuiltWith

The last model we want to look at is BuiltWith. BuiltWith scans website titles to determine what the site is powered by and, like GitHub and Tiobe, provides rankings of programming language popularity and trends.

Builtwith provides an interesting look at the explosion of websites built with PHP (almost tripling from 2013 to 2016) before declining and normalizing in 2017. The number of websites using PHP has remained almost unchanged from 2017 to present.

BuiltWith PHP Usage

This shows (as we have seen with GitHub and Tiobe) that other languages ​​have become more popular, such as JavaScript and Node.js. This doesn't mean that PHP is no longer used or relied upon, either, but there is more competition and there are other viable options, while PHP is sometimes left alone in being the goto language for web development.

In fact, when we looked at where PHP ranked among all technologies at BuiltWith, PHP received the following BuiltWith awards:

• Most popular framework category on the entire Internet.

• Most popular among top 10k websites in Frames category.

• Most popular among top 100k websites in Frames category.

• Most popular among top 1 million sites in Frames category.

Conclusion

PHP’s popularity has declined from the heights of 10 years ago, but it remains the most popular programming language powering the web. It's important to remember that every tool has pros and cons, and PHP gets some of the bad rap it gets compared to languages ​​that are designed to accomplish tasks or build programs that PHP was never designed for.

It's also important to remember that many of the early criticisms of PHP came from the fact that it was a procedural programming language and did not include object-oriented programming features. These features were added in PHP 4, and with PHP 7 and 8, OOP has become a staple of the PHP language.

PHP is a viable, powerful language used by almost every business and by many large and small businesses. In fact, it powers over 50% of the top 10,000 websites on the web! With this amount of usage, it's safe to assume that PHP will remain a prominent language for years to come.

The above is the detailed content of Is PHP a dying language?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
php
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template