Lugaru's Epsilon
Programmer's
Editor

Context:
Epsilon User's Manual and Reference
   Commands by Topic
      . . .
      Changing Text
         Inserting and Deleting
         Killing Text
         Clipboard Access
         . . .
         Hex Mode
      Language Modes
         . . .
         Makefile Mode
         Perl Mode
         PHP Mode
         PostScript Mode
         Python Mode
         . . .
      More Programming Features
         Navigating in Source Code
         Pulling Words
         Accessing Help
         Context-Sensitive Help
         Commenting Commands
      . . .

Previous   Up    Next
Perl Mode  Commands by Topic   PostScript Mode


Epsilon User's Manual and Reference > Commands by Topic > Language Modes >

PHP Mode

Epsilon automatically enters PHP mode when you read a file with an extension of .php, .php3, .php4, or .sphp. In PHP mode, Epsilon does appropriate syntax highlighting, tagging, and similar tasks. PHP mode is almost identical to HTML mode. (See HTML/XML/CSS Modes.) In both, codes such as <? ?> mark PHP scripting, and text outside of these markers is treated as HTML.

When the cursor is on a brace, bracket, or parenthesis in PHP code, Epsilon will try to locate its matching brace, bracket, or parenthesis, and highlight them both. If the current character has no match, Epsilon will not highlight it. Set the variable auto-show-php-delimiters to zero to disable this feature.

When you use the indent-for-comment command to insert a comment, the php-comment-style variable controls which type of comment Epsilon inserts. The value 1 (the default) inserts #, the value 2 inserts //, and any other value inserts /*.

PHP mode's automatic indentation features use a modified version of C mode. See C Mode for information on customizing indentation. PHP uses a different set of customization variables whose names all start with php- instead of c- but work the same as their C mode cousins. These include php-align-contin-lines, php-brace-offset, php-closeback, php-contin-offset, php-label-indent, php-top-braces, php-top-contin, php-top-struct, and php-topindent. Set php-indent if you want to use an indentation in PHP files that's not equal to one tab stop. The php-top-level-indent variable sets the indentation of PHP code outside any function definition.

PHP's syntax highlighting shares its color classes with Perl mode. The color class perl-comment, for instance, defines the color of comments in both languages.

Standard bindings:

    php-mode
 



Previous   Up    Next
Perl Mode  Commands by Topic   PostScript Mode


Lugaru Copyright (C) 1984, 2012 Lugaru Software Ltd. All Rights Reserved.