: This article mainly introduces the PHP auto-completion function that teaches you how to customize EditPlus. For more information about PHP tutorials, see. Preface
When writing PHP, I generally use lightweight editors such as EditPlus instead of IDE. EditPlus has a PHP auto-completion function, but how can auto-completion be subject to people? Obviously, we have to do what we want. Next, let's build your EditPlus together.
Understanding php. stx and php. acp
- First, you need to know two files: php. stx and php. acp. Among them, php. stx is related to php syntax. you can download the corresponding php. stx from the Internet based on your php version.
- Then, php. acp is the file for automatic configuration completion, that is, the core of our operations.
Open the php. acp file
In the installation directory of your EditPlus, there will be a php. acp file, which stores the relevant configuration information for automatic completion. Open it as follows:
1. you can open it directly in the file directory in the form of Notepad or in EditPlus. I chose the latter;
2. click "Document" in the toolbar and select "Permanent Settings" from the drop-down menu ):
3. then, Preferences (Preferences) is enabled. click File-> Settings & syntax in sequence. Select PHP in File types.
4. in the Settings and syntax column below, click the buttons of the three vertices before opening in the Syntax file column:
5. select php. stx and click "open ":
6. select Auto Completion in the next column and click "Open" next to it ":
7. click "OK" and you will find that the php. acp file has been opened:
Modify the php. acp file
Below we will familiarize ourselves with some syntax in the php. acp file to facilitate the modification of the file for personalized purposes:
1. The first thing we can see is: # TITLE = PHP/PHPDoc, which indicates that this file belongs to the PHP configuration file, followed by some of the following; the hitting line is a comment
2. Then: # CASE = y, which indicates that the subsequent configuration is CASE sensitive !!!
3. finally, the main course is coming. now we have a set of configurations. for example, in the image, # T indicates the keyword, and # T = if, that is to say, the keyword of this configuration is if. when if is input in the text and press enter, if is replaced and the following characters are displayed:
If ()
{
}
4. careful students may find that there is a blue "^ !" If you enter if in the text, press enter to replace it:
If ()
{
}
At the same time, the mouse will be placed at "^ !" Location. In this example, it is waiting for you to enter the condition.
5. Based on this syntax, you can have your own tons of personalized configuration!
6. the above syntax applies not only to PHP, but also to the automatic configuration of other languages. Next, start your DIY journey!
Note: If you like the color scheme of EditPlus in the text, you can click here:
Http://blog.csdn.net/yongf2014/article/details/47278027
Copyright disclaimer: You are welcome to repost it. You are welcome to spread it. please contact me before reprinting. thank you for your cooperation.
The above describes the PHP auto-completion function that teaches you how to customize EditPlus, including some content, and hope to help friends who are interested in PHP tutorials.