search
HomeBackend DevelopmentPHP TutorialTeach you step by step how to customize EditPlus' PHP auto-complete function

Written before

When writing PHP, I usually use lightweight editors such as EditPlus instead of IDEs. EditPlus has a PHP auto-completion function, but how can the auto-completion be controlled by others? Obviously you have to do whatever you want. Now, let us DIY together to create your own EditPlus.

Get to know php.stx and php.acp

  1. First of all, you need to know two files: php.stx and php.acp. Among them, php.stx is related to the syntax of PHP. You can download the corresponding php.stx from the Internet according to your PHP version.
  2. Then, php.acp is the file that configures automatic completion, which is the core of our operation.

Open the php.acp file

In your EditPlus installation directory, there will be a php.acp file, which stores the relevant configuration information for automatic completion. Let’s open it:
Teach you step by step how to customize EditPlus PHP auto-complete function. You can open it directly in Notepad in the file directory, or you can open it in EditPlus. I chose the latter;
Teach you step by step how to customize EditPlus PHP auto-complete function. Click: Document in the toolbar and select the last item in the drop-down menu: Permanent Settings (settings, long-term effective):
Teach you step by step how to customize EditPlus PHP auto-complete function
Teach you step by step how to customize EditPlus PHP auto-complete function. Then, open Preferences and click: File->Settings&syntax. Select PHP in File types.
Teach you step by step how to customize EditPlus PHP auto-complete function
Teach you step by step how to customize EditPlus PHP auto-complete function. Then in the Settings and syntax column below, click the three-dot button in front of Open in the Syntax file column:
Teach you step by step how to customize EditPlus PHP auto-complete function
Teach you step by step how to customize EditPlus PHP auto-complete function. Select php.stx and click "Open":
Teach you step by step how to customize EditPlus PHP auto-complete function
Teach you step by step how to customize EditPlus PHP auto-complete function. Check Auto Completion in the next column, and then click "Open" next:
Teach you step by step how to customize EditPlus PHP auto-complete function
Teach you step by step how to customize EditPlus PHP auto-complete function. Click "OK". You will find that the php.acp file has been opened:
Teach you step by step how to customize EditPlus PHP auto-complete function

Modify the php.acp file

Let's get familiar with some of the syntax in the php.acp file so that we can easily modify the file. Purpose of personalization:
Teach you step by step how to customize EditPlus PHP auto-complete function. The first thing we see is: #TITLE=PHP/PHPDoc, which means that the file belongs to the PHP configuration file, and the following lines starting with; are comments
Teach you step by step how to customize EditPlus PHP auto-complete function
Teach you step by step how to customize EditPlus PHP auto-complete function. Then: #CASE=y, which means that the subsequent configuration is case-sensitive! ! !
Teach you step by step how to customize EditPlus PHP auto-complete function
Teach you step by step how to customize EditPlus PHP auto-complete function. Finally, the main dish is here. Now it is a group of configurations. Take the following picture as an example. In the picture, #T means keyword, and #T=if, which means the keyword of this configuration is if. , when you enter if in the text and press Enter, if will be replaced and the following characters will be displayed:
if ()
{

}
Teach you step by step how to customize EditPlus PHP auto-complete function
Teach you step by step how to customize EditPlus PHP auto-complete function. Careful students may find that a blue "^!" is missing, which indicates the position of the mouse. That is to say, when you enter if in the text and press Enter, it will be replaced with:
if( )
{

}
At the same time, the mouse will be at the location of "^!". In this case, it is waiting for you to enter the condition
Teach you step by step how to customize EditPlus PHP auto-complete function. According to this syntax, you can have tons of personalized configurations of your own!
Teach you step by step how to customize EditPlus PHP auto-complete function. The above syntax is not only applicable to PHP, but also to the automatic completion configuration of other languages. Now, start your DIY journey!

Note: If you like the color scheme of my EditPlus in this article, you can go here:
http://blog.csdn.net/yongfTeach you step by step how to customize EditPlus PHP auto-complete function0Teach you step by step how to customize EditPlus PHP auto-complete functionTeach you step by step how to customize EditPlus PHP auto-complete function/article/details/Teach you step by step how to customize EditPlus PHP auto-complete functionTeach you step by step how to customize EditPlus PHP auto-complete functionTeach you step by step how to customize EditPlus PHP auto-complete functionTeach you step by step how to customize EditPlus PHP auto-complete functionTeach you step by step how to customize EditPlus PHP auto-complete function0Teach you step by step how to customize EditPlus PHP auto-complete functionTeach you step by step how to customize EditPlus PHP auto-complete function

Copyright Statement: Welcome to reprint and spread, but please contact me before reprinting, thank you for your cooperation

The above has introduced a step-by-step guide to personalizing the PHP auto-completion function of EditPlus, including various aspects. I hope it will be helpful to friends who are interested in PHP tutorials.

Statement
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
PHP Performance Tuning for High Traffic WebsitesPHP Performance Tuning for High Traffic WebsitesMay 14, 2025 am 12:13 AM

ThesecrettokeepingaPHP-poweredwebsiterunningsmoothlyunderheavyloadinvolvesseveralkeystrategies:1)ImplementopcodecachingwithOPcachetoreducescriptexecutiontime,2)UsedatabasequerycachingwithRedistolessendatabaseload,3)LeverageCDNslikeCloudflareforservin

Dependency Injection in PHP: Code Examples for BeginnersDependency Injection in PHP: Code Examples for BeginnersMay 14, 2025 am 12:08 AM

You should care about DependencyInjection(DI) because it makes your code clearer and easier to maintain. 1) DI makes it more modular by decoupling classes, 2) improves the convenience of testing and code flexibility, 3) Use DI containers to manage complex dependencies, but pay attention to performance impact and circular dependencies, 4) The best practice is to rely on abstract interfaces to achieve loose coupling.

PHP Performance: is it possible to optimize the application?PHP Performance: is it possible to optimize the application?May 14, 2025 am 12:04 AM

Yes,optimizingaPHPapplicationispossibleandessential.1)ImplementcachingusingAPCutoreducedatabaseload.2)Optimizedatabaseswithindexing,efficientqueries,andconnectionpooling.3)Enhancecodewithbuilt-infunctions,avoidingglobalvariables,andusingopcodecaching

PHP Performance Optimization: The Ultimate GuidePHP Performance Optimization: The Ultimate GuideMay 14, 2025 am 12:02 AM

ThekeystrategiestosignificantlyboostPHPapplicationperformanceare:1)UseopcodecachinglikeOPcachetoreduceexecutiontime,2)Optimizedatabaseinteractionswithpreparedstatementsandproperindexing,3)ConfigurewebserverslikeNginxwithPHP-FPMforbetterperformance,4)

PHP Dependency Injection Container: A Quick StartPHP Dependency Injection Container: A Quick StartMay 13, 2025 am 12:11 AM

APHPDependencyInjectionContainerisatoolthatmanagesclassdependencies,enhancingcodemodularity,testability,andmaintainability.Itactsasacentralhubforcreatingandinjectingdependencies,thusreducingtightcouplingandeasingunittesting.

Dependency Injection vs. Service Locator in PHPDependency Injection vs. Service Locator in PHPMay 13, 2025 am 12:10 AM

Select DependencyInjection (DI) for large applications, ServiceLocator is suitable for small projects or prototypes. 1) DI improves the testability and modularity of the code through constructor injection. 2) ServiceLocator obtains services through center registration, which is convenient but may lead to an increase in code coupling.

PHP performance optimization strategies.PHP performance optimization strategies.May 13, 2025 am 12:06 AM

PHPapplicationscanbeoptimizedforspeedandefficiencyby:1)enablingopcacheinphp.ini,2)usingpreparedstatementswithPDOfordatabasequeries,3)replacingloopswitharray_filterandarray_mapfordataprocessing,4)configuringNginxasareverseproxy,5)implementingcachingwi

PHP Email Validation: Ensuring Emails Are Sent CorrectlyPHP Email Validation: Ensuring Emails Are Sent CorrectlyMay 13, 2025 am 12:06 AM

PHPemailvalidationinvolvesthreesteps:1)Formatvalidationusingregularexpressionstochecktheemailformat;2)DNSvalidationtoensurethedomainhasavalidMXrecord;3)SMTPvalidation,themostthoroughmethod,whichchecksifthemailboxexistsbyconnectingtotheSMTPserver.Impl

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Article

Hot Tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Safe Exam Browser

Safe Exam Browser

Safe Exam Browser is a secure browser environment for taking online exams securely. This software turns any computer into a secure workstation. It controls access to any utility and prevents students from using unauthorized resources.

SublimeText3 English version

SublimeText3 English version

Recommended: Win version, supports code prompts!

PhpStorm Mac version

PhpStorm Mac version

The latest (2018.2.1) professional PHP integrated development tool