Nov
15
Get ctp File Recognized in Dreamweaver
November 15, 2008 |
To get color code, syntax highlight style for ctp files in Dreamweaver is easy.
There are two dreamweaver configuration files you need to edit to make ctp files have HTML like color code and view in design view.
1. Edit the Extensions.txt file
Locate the Extensions.txt file within the Dreamweaver user configuration folder. The location of this folder depends on the operating system and the version of Dreamweaver:
* Dreamweaver CS3 on Windows Vista:
C:\Users\[username]\AppData\Roaming\Adobe\Dreamweaver 9\Configuration
* Dreamweaver 8 on Windows Vista:
C:\Users\[username]\AppData\Roaming\Macromedia\Dreamweaver 8\Configuration
* Dreamweaver CS3 on Windows XP:
C:\Documents and Settings\[username]\Application Data\Adobe\Dreamweaver 9\Configuration
* Dreamweaver 8 on Windows XP & 2000:
C:\Documents and Settings\[username]\Application Data\Macromedia\Dreamweaver 8\Configuration
* Dreamweaver CS3 on Mac OS X:
Mac HD:Users:[username]:Library:Application Support:Adobe:Dreamweaver 9:Configuration
* Dreamweaver 8 on Mac OS X:
Mac HD:Users:[username]:Library:Application Support:Macromedia:Dreamweaver 8:Configuration
2. Open Extensions.txt in any external text editor like Notepad or Text Editor. Do not modify the Dreamweaver configuration files in Dreamweaver itself.
3. You should be able to see a line similar to the one below:
HTM,HTML,SHTM,SHTML,HTA,HTC,XHTML,STM,SSI,JS,AS,ASC,ASR,XML,XSL,
XSD,DTD,XSLT,RSS,RDF,LBI,DWT,ASP,ASA,ASPX,ASCX,ASMX,CONFIG,CS,
CSS,CFM,CFML,CFC,TLD,TXT,PHP,PHP3,PHP4,PHP5,TPL,LASSO,JSP,JSF,VB,
VBS,VTM,VTML,INC,JAVA,EDML,WML:All Documents
4. Now add CTP to the end of the list just before the :All Documents, so now the new list should look like:
HTM,HTML,SHTM,SHTML,HTA,HTC,XHTML,STM,SSI,JS,AS,ASC,ASR,XML,XSL,
XSD,DTD,XSLT,RSS,RDF,LBI,DWT,ASP,ASA,ASPX,ASCX,ASMX,CONFIG,CS,
CSS,CFM,CFML,CFC,TLD,TXT,PHP,PHP3,PHP4,PHP5,TPL,LASSO,JSP,JSF,VB,
VBS,VTM,VTML,INC,JAVA,EDML,WML,CTP:All Documents
5. You have just added ctp file as a Dreamweaver document, the next step is to specifically define it as a HTML document. Search for the line: HTM,HTML,HTA,HTC,XHTML:HTML Documents
6. Now add CTP to the end of the list:
HTM,HTML,HTA,HTC,XHTML, CTP:HTML Documents
7. Now you have made ctp files recognizedly by Dreamweaver, the next step is to make the syntax color highlighted.
Locate the MMDocumentTypes.xml file in the main Dreamweaver configuration folder (not the Dreamweaver user configuration folder). The location of this folder depends on the operating system and the version of Dreamweaver:
* Dreamweaver CS3 on Windows Vista & XP:
C:\Program Files\Adobe\Adobe Dreamweaver CS3\Configuration\DocumentTypes
* Dreamweaver 8 on Windows Vista, XP & 2000:
C:\Program Files\Macromedia\Dreamweaver 8\Configuration\DocumentTypes
* Dreamweaver CS3 on Mac OS X:
Mac HD:Applications:Adobe Dreamweaver CS3:Configuration:Document Types
* Dreamweaver 8 on Mac OS X:
Mac HD:Applications:Macromedia Dreamweaver 8:Configuration:Document Types
8. Open MMDocumentTypes.xml in any external text editor like Notepad or Text Editor. Do not modify the Dreamweaver configuration files in Dreamweaver itself.
<documenttype id="HTML" internaltype="HTML" winfileextension="html,htm,shtml,shtm,stm,tpl,lasso,xhtml" macfileextension="html,htm,shtml,shtm,tpl,lasso,xhtml,ssi" file="Default.html" writebyteordermark="false">
9. Add the desired extension to the winfileextension and macfileextension attributes of the documenttype tag. For example:
<documenttype id="HTML" internaltype="HTML" winfileextension="html,htm,shtml,shtm,stm,tpl,lasso,xhtml,ctp" macfileextension="html,htm,shtml,shtm,tpl,lasso,xhtml,ssi,ctp" file="Default.html" writebyteordermark="false">
10. now after editing and saving the two files above, close and restart your Dreamweaver again, open a file with the extension .ctp and you should be able to see the color and formatting being recognized!
Similar Posts
- HTML Code
- IE6 HTML CSS div height Extra Space
- Make HTML Elements Appear on Top of Flash Movie
- alt Tag tooltip on Firefox
- No Flash Replace with Image
Comments
5 Comments so far



































Thanks A LOT! I’m using DW to open CTP files for CakePHP, this is really useful. I don’t syntax them as HTML, bus as PHP files.
Good article, especially with all the details from the different OS’ses :) .
Hi, Marco
I am glad it helped you. I also use CakePHP, that’s why I wrote this article. :)
Thanks for the tips. It was easy to understand, even for a inexperienced loser like myself.
Thank a Lot
I can’t complete the steep 8 and 9, cause VISTA don’t allow me to save on that directories.