10 coding tools that the PHP developer should pay attention to

Source: Internet
Author: User
Tags coding standards manual interface pear php code hosting file permissions continuous integration tools

We tend to be frustrated when we often have to deal with things like manual code testing and deploying such tedious repetitive work, but we've been trying to be efficient. This article will introduce you to the 10 PHP development tools that can help you meet that requirement and give you more time to focus on building better Web pages.

1. PHPUnit

Testing is a very important part of software development, but many developers just give a little time to test because it's really time-consuming, tedious, and error-prone. To address these issues, the automated testing tool enables developers to write a series of test scripts that can be easily executed and executed according to the scheduled tasks. These automated test tools typically provide a test report detailing the results of each test. PHP developers have a pretty good test framework for automated phpunit. Based on a very popular test-driven development approach, such as xunit,phpunit allows developers to use PHP syntax to write test cases, and then execute tests with very simple command-line tools. You can even integrate phpunit with some continuous integration tools such as Phpundercontrol.

2. Phing

As Web development projects become more complex, developers face a whole host of deployment tasks that are not just as simple as uploading files from a developer's machine to a production server. For example, avoid uploading the development environment files, such as image template, processing server specified file permissions and parameter configuration, such as user name password, and how to change errors when the recovery as soon as possible, these problems are often encountered by developers. To solve these problems, developers use a dedicated build tool that makes the file transfer process more efficient because it only synchronizes files that have changed. Building tools can also be easily tailored to the environment in which they are deployed.

3. GitHub

Versioning can bring a lot of benefits to the project, including experimental branches that can build code, rollback unwanted changes, see which team members have recently been modified by a file, and monitor progress through the log. While there are many open source versioning tools, Git is now my favorite. The rise of git has largely benefited from a GitHub Web site that provides Third-party hosting services that provide a host of hosting services to developers. GitHub meets the needs of developers and even provides hosting services for open source projects. Now that over 1 million of the hosting apps are on top, GitHub provides valuable services to developers without spending a lot of money and time looking for third-party hosting services.

4. firephp

Many developers are familiar with Firefox's plugin firebug, which makes it easy for you to check a page's html,css and JavaScript syntax problems. Using firephp, you can also use an interface like Firebug to check for errors in PHP syntax and selected profiling data.

Recommended reading: firephp: Debug your PHP code like Firebug

5. XDebug

After using a test tool like PHPUnit, you can help catch errors after you've written the code, and sometimes you need to use some help tools to help you understand the causes of these problems. Many PHP developers use a good debugging tool Xdebug, which helps you check the status of your code and provides tools to track and dissect code performance, view object content, and other features.

6. PHP extensions and application libraries

Although you may think your ideas are unique and special, there is a great chance that you are trying to write code that has been written by many other programmers before. To help developers overcome such barriers, PHP developers regularly contribute PHP extensions and application libraries, such as the famous pear. Pear contains 560 packages that provide fast solutions such as caching, encryption, user authentication, and payment processing. You can always find the right solution for you in pear.

To help manage Pear package applications, you can install the Pear Package Management tool, which provides a command-line interface to install, upgrade, and delete packages.

Pear Package management tool: http://pear.php.net/manual/en/installation.getting.php

7. Php_codesniffer

As with the editorial debate, the debate over the coding style is more ironic. Even so, the coding standards that pear advocates seem to be gaining a place in the PHP community, but you or your team may still not adopt such standard conventions, which will lead to inconsistent style code.

To avoid code-style inconsistencies, consider installing php_codesniffer, a nice pear package that analyzes PHP programs, Javascrip, and CSS files and examines which are inconsistent with well-defined code styles. Although you can define your own coding style, Php_codesniffer's coding style is very convenient.

8. Phpdocumentor

It's a frustrating task to understand code from obscure code annotations, even if the code was written by yourself before. Like testing, writing a document is still one of several tasks that developers want to evade. To mitigate such pain, you might consider using automated documentation tools like Phpdocumentor. Phpdocumentor supports simple document rule syntax to parse your code and generate friendly documentation.

9. Php_beautifier

Another factor that blocks reading code is bad code formatting, because in scripting languages like PHP, it's easy to indent and then create bad code formatting. You can use the package php_beautifier in pear to automate the formatting of your code.

Phpundercontrol

If you are considering the tools mentioned above, then you can download the Phpundercontrol tool, which is built on CruiseControl. Phpundercontrol includes a number of PHP tools, such as Phpunit,phpdocumentor, and provides a unified interface management.

Summary

Do you have any favorite tools to improve the efficiency of PHP coding?







Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.