Turn on syntax highlighting for editing .thtml files in Vim
If you use Vim to edit your Views, here's how to turn on syntax highlighting.
If you use VIm as your text editor like I do, you probably find the syntax highlighting helpful. Unfortunately, files ending in *.thtml aren't recognized by Vim. Here's how to fix that:
(Examples are for Unix)
1. Create a user runtime directory:
Download code
2. Create the following file:
Download code
It should contain:
Download code
3. Restart Vim, if need be.
This should make editing your Views with Vim a little easier.
Sources:
http://www.vim.org/htmldoc/filetype.html
(Examples are for Unix)
1. Create a user runtime directory:
Download code
mkdir ~/.vim
2. Create the following file:
Download code
vi ~/.vim/filetype.vim
It should contain:
Download code
" my filetype file
if exists("did_load_filetypes")
finish
endif
augroup filetypedetect
au! BufRead,BufNewFile *.thtml setfiletype html
augroup END
3. Restart Vim, if need be.
This should make editing your Views with Vim a little easier.
Sources:
http://www.vim.org/htmldoc/filetype.html
Comments
Comment
1 Easier than that
au BufNewFile,BufRead *.thtml setfiletype php
(I prefer php synax rather than just html)
Comment
2 Syntax Highlighting for Dreamweaver
Open
c:\Program Files\Macromedia\Dreamweaver MX\Configuration\DocumentTypes\MMDocumentTypes.xmlLook for
winfileextension="php,php3"ܡםr^t屔而)ѕͥ̈( if you're on a mac and simply add "thtml" (or "ctp" for 1.2) to the list so you have:winfileextension="php,php3,thtml"ormacfileextension="php,php3,thtml"Save it, and restart Dreamweaver and you should be good to go.
Hope this helps someone.
Source:
http://www.phpbuilder.com/board/archive/index.php/t-10224922.html
Comment
3 Clarification
I'm sure you meant "thtml" (or "ctp" for 1.2) instead of "inc" :D