syn keyword phtmlFunctions reg_Match reg_replace reg_Search Rename Reset return contained
syn keyword phtmlFunctions rewind rewindDir RmDir rSort SetCookie SetErrorReporting contained
syn keyword phtmlFunctions SetLogging SetShowInfo SetType shl shr Sin Sleep contained
syn keyword phtmlFunctions Solid_Close Solid_Connect Solid_Exec Solid_FetchRow contained
syn keyword phtmlFunctions Solid_FieldName Solid_FieldNum Solid_FreeResult contained
syn keyword phtmlFunctions Solid_NumFields Solid_NumRows Solid_Result Sort contained
syn keyword phtmlFunctions Spundtex Sprintf Sqrt Srand strchr strtr contained
syn keyword phtmlFunctions StripSlashes strlen strchr strstr strtok strtolower contained
syn keyword phtmlFunctions strtoupper strval substr sybSQL_CheckConnect contained
syn keyword phtmlFunctions sybSQL_DBUSE sybSQL_Connect sybSQL_Exit contained
syn keyword phtmlFunctions sybSQL_Fieldname sybSQL_GetField sybSQL_IsRow contained
syn keyword phtmlFunctions sybSQL_NextRow sybSQL_NumFields sybSQL_NumRows contained
syn keyword phtmlFunctions sybSQL_Query sybSQL_Result sybSQL_Result sybSQL_Seek contained
syn keyword phtmlFunctions Symlink syslog System Tan TempNam Time Umask UniqId contained
syn keyword phtmlFunctions Unlink Unset UrlDecode UrlEncode USleep Virtual contained
syn keyword phtmlFunctions SecureVar contained
" Identifier
syn match phtmlIdentifier "$[a-zA-Z_][a-zA-Z0-9_]*" contained contains=phtmlEnvVar,phtmlIntVar
" Conditional
syn keyword phtmlConditional if else elseif endif switch endswitch contained
" Repeat
syn keyword phtmlRepeat while endwhile contained
" Repeat
syn keyword phtmlLabel case default contained
" Statement
syn keyword phtmlStatement break return continue exit contained
" Operator
syn match phtmlOperator "[-=+%^&|*!]" contained
syn match phtmlOperator "[-+*/%^&|]=" contained
syn match phtmlOperator "/[^*]"me=e-1 contained
syn match phtmlOperator "/$" contained
syn match phtmlRelation "&&" contained
syn match phtmlRelation "||" contained
syn match phtmlRelation "[!=<>]=" contained
syn match phtmlRelation "[<>]" contained
" Include
syn keyword phtmlInclude include contained
" Definesag
syn keyword phtmlDefine Function contained
" String
syn region phtmlString keepend matchgroup=None start=+"+ skip=+\\\\\|\\"+ end=+"+ contains=phtmlIdentifier,phtmlSpecialChar,@phtmlSql contained
" Number
syn match phtmlNumber "-\=\<\d\+\>" contained
" Float
syn match phtmlFloat "\(-\=\<\d+\|-\=\)\.\d\+\>" contained
" SpecialChar
syn match phtmlSpecialChar "\\[abcfnrtyv\\]" contained
syn match phtmlSpecialChar "\\\d\{3}" contained contains=phtmlOctalError
syn match phtmlSpecialChar "\\x[0-9a-fA-F]\{2}" contained
syn match phtmlOctalError "[89]" contained
syn match phtmlParentError "[)}\]]" contained
" Todo
syn keyword phtmlTodo TODO Todo todo contained
" Parents
syn cluster phtmlInside contains=phtmlComment,phtmlFunctions,phtmlIdentifier,phtmlConditional,phtmlRepeat,phtmlLabel,phtmlStatement,phtmlOperator,phtmlRelation,phtmlString,phtmlNumber,phtmlFloat,phtmlSpecialChar,phtmlParent,phtmlParentError,phtmlInclude
syn cluster phtmlTop contains=@phtmlInside,phtmlInclude,phtmlDefine,phtmlParentError,phtmlTodo
syn region phtmlParent matchgroup=Delimiter start="(" end=")" contained contains=@phtmlInside
syn region phtmlParent matchgroup=Delimiter start="{" end="}" contained contains=@phtmlInside
syn region phtmlParent matchgroup=Delimiter start="\[" end="\]" contained contains=@phtmlInside
syn region phtmlRegion keepend matchgroup=Delimiter start="<?" skip=+(.*>.*)\|".\{-}>.\{-}"\|/\*.\{-}>.\{-}\*/+ end=">" contains=@phtmlTop
syn region phtmlRegion matchgroup=Delimiter start="<?" end=">" contains=@phtmlTop contained
syn region phtmlRegionInsideHtmlTags keepend matchgroup=Delimiter start="<?" skip=+(.*>.*)\|/\*.\{-}>.\{-}\*/+ end=">" contains=@phtmlTop contained
" sync
if exists("phtml_minlines")
exec "syn sync minlines=" . phtml_minlines
endif
if !exists("did_phtml_syntax_inits")
let did_phtml_syntax_inits = 1
" The default methods for highlighting. Can be overridden later