Dreamweaver

Dreamweaver can edit your PHP, template and CSS files just fine, and in some cases (XTemplate, PHPTAL) with a graphical preview.

Find the Dreamweaver configuration files, MMDocumentTypes.xml and Extensions.txt. where they are depends on what platform is being used - the Find file function is your friend here.

For Dreamweaver CS3 you need to add the extensions by going to the edit menu > preferences. In the File Types/Editors section there is a place that identifies extensions you can "Open in Code View." Add the extensions listed below.

In Extensions.txt

Change the line ending in

: All Documents
to include
TAL,XTMPL,MODULE,THEME,ENGINE,INFO,INC

Likewise, add TAL,XTMPL to the line ending in : HTML files
and
MODULE,THEME,ENGINE,INC to the : PHP files line.

In MMDocumentTypes.xml

you likewise want to add tal and xtmpl file types to the file type descriptions, e.g. change the line beginging documenttype id="HTML" to be

<documenttype id="HTML" internaltype="HTML" winfileextension="htm,html,shtml,shtm,stm,tpl,lasso,xhtml,tal,xtmpl" macfileextension="htm,html,shtml,shtm,tpl,lasso,xhtml,tal,xtmpl" file="Default.html" writebyteordermark="false">

and likewise add .theme, .module and .engine to the appropriate section

<documenttype id="PHP_MySQL" servermodel="PHP MySQL" internaltype="Dynamic" winfileextension="php,php3,php4,theme,module,engine" macfileextension="php,php3,php4,theme,module,engine" file="Default.php" writebyteordermark="false">

The local copy of your site can now be edited in Dreamweaver.

Notes for Mac OS X

On OS X with CS3 installed, your Extension.txt is in

Macintosh HD/Users/{Your User Name}/Library/Application Support/Adobe/Dreamweaver 9/Configuration/

The MMDocumentTypes.xml is in

Macintosh HD/Applications/Dreamweaver CS3/configuration/DocumentTypes/

You might need to change the owner of this file (Right/Command Click + Get Info, Owner)

or in terminal
sudo chmod 777 MMDocumentTypes.xml

Related Dreamweaver Support Article

If you're interested in how Dreaweaver's file types can be tweaked then read this Adobe knowledgebase article (#tn_16410).

It would be better to add

Vril - November 4, 2007 - 15:08

It would be better to add .install extension also.

Drupal Themer Kit Pro Dreamweaver extension

ccharlton - March 25, 2008 - 22:44

I posted info on the other Drupal Dreamweaver extension over at http://groups.drupal.org/node/9666

These new extensions should all help Dreamweaver users to be more comfortable when approaching Drupal.

No more manual configuration changes

ccharlton - April 22, 2008 - 18:24

The Drupal API extension for Dreamweaver is made to apply these tweaks for you in an easy (free) extension.

 
 

Drupal is a registered trademark of Dries Buytaert.