These forums are now archived.


Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 9 posts ] 
Author Message
PostPosted: Wed Sep 22, 2004 4:11 pm 
Offline
NetHosted Customer
User avatar

Joined: Mon Sep 20, 2004 11:20 pm
Posts: 92
Location: London, UK


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Sep 22, 2004 4:24 pm 
Offline
NetHosted Staff
User avatar

Joined: Mon Mar 22, 2004 4:36 pm
Posts: 7373

_________________
| Andrew Bassett
| Managing Director, NetHosted Ltd.
| Earn £30 every time you refer someone to us!
| Follow us on Twitter:
| Members, tell us what of NetHosted!


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Sep 22, 2004 4:26 pm 
Offline
NetHosted Customer
User avatar

Joined: Mon Sep 20, 2004 11:20 pm
Posts: 92
Location: London, UK
Hello Andrew,

At present my Index.html is in the public_html directory. Is this thr correct place for it to be in?

Carlos


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Sep 22, 2004 4:28 pm 
Offline
NetHosted Staff
User avatar

Joined: Mon Mar 22, 2004 4:36 pm
Posts: 7373

_________________
| Andrew Bassett
| Managing Director, NetHosted Ltd.
| Earn £30 every time you refer someone to us!
| Follow us on Twitter:
| Members, tell us what of NetHosted!


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Sep 22, 2004 4:31 pm 
Offline
NetHosted Customer
User avatar

Joined: Mon Sep 20, 2004 11:20 pm
Posts: 92
Location: London, UK


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Sep 22, 2004 4:42 pm 
Offline
NetHosted Customer
User avatar

Joined: Mon Sep 20, 2004 11:20 pm
Posts: 92
Location: London, UK


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Sep 22, 2004 4:43 pm 
Offline
NetHosted Staff
User avatar

Joined: Mon Mar 22, 2004 4:36 pm
Posts: 7373

_________________
| Andrew Bassett
| Managing Director, NetHosted Ltd.
| Earn £30 every time you refer someone to us!
| Follow us on Twitter:
| Members, tell us what of NetHosted!


Top
 Profile  
Reply with quote  
PostPosted: Wed Sep 22, 2004 7:10 pm 
Offline
NetHosted Customer
User avatar

Joined: Mon Sep 20, 2004 11:20 pm
Posts: 92
Location: London, UK
Ok.. It's me again. I found this info to enable DW MX to edit .tpl files.
It's untested, so I will let you know how I get on.

How to customize Macromedia Dreamweaver MX
--------------------------------------------------------------------------------------------------

This tutorial will teach you how to customize Macromedia Dreamweaver MX, in terms of the ability to customize the different extensions that it has, to suit the type of file that you wish to edit, be it .tpl files, or .cfg files. Simply modify the extensions to suit your situation - it can literally be any type of code file.

Files Required To Modify (3 in total):

* Extensions.txt
* DocumentStyles.xml
* MMDocumentTypes.xml


It is strongly recommended that you back up all of these files before modifying them.

Note: This tutorial was created for Windows XP Professional/Windows 2000 users. However, you can use the Search feature (Window + S), to search for the appropriate files needed to be modified.


Setting Up Dreamweaver To Handle Custom Extensions

Note: It is important that you do this while Dreamweaver is closed. If you have an error saying that the extension could not be added, it will be due to you having missed a stage. Simply go through the stages, and make sure you have correctly added the necessary data.

Step 1 :

Open Extensions.txt from (non-xp users, use the windows search function (Window + S) :

Code:
C:\Documents and Settings\User\Application Data\Macromedia\Dreamweaver MX\Configuration


You will see 21 lines of extensions, more if you have previously modified it. Add the following at the end of the file, at what would be line 22:

Code:
TPL:PHPBB Template Documents


Also, you will find a long list of extensions at line 1, where each extension is seperated by a comma (,). All extensions MUST be in CAPITAL LETTERS (Upper Case).

Once you have done that, save and close.

This will add the ability to select these files from the Dreamweaver Open Dialog. However, it will open unknown files as though text files. Alter the position to change the place in the menu. We still need to do a little more before we can get it to work correctly.

Step 2 : Getting Dreamweaver To Understand

You'll now need to open two other files. It is important that you alter these files properly, otherwise you could get dreamweaver to start behaving in ways you do not want it to.

Note: All the directory paths hereon are relative to the installation path.

Open the following file using a text editor - do not use Dreamweaver:

Code:
Configuration\Strings\documenttypes.xml


Go to the bottom of the file. By default there will be 66 lines of code, with a list of items, numbering from 0 to 63.

Add the following line of code after number 63:

Code:
<string id="mmdocumenttypes_64" value="TPL" />
<string id="mmdocumenttypes_65" value="<![CDATA[TPL document]]>" />



Once done, save and close.

Now open up the following file:

Code:
Configuration\DocumentTypes\MMDocumentTypes.xml


You'll see a lot of code, each of which is responsible for defining what extension is what, and when open what Dreamweaver will do to it. You may also notice that each item is numbered, 0-63, more if you have altered the file previously.

Add the following to the end at line 258:

Code:
<documenttype id="TMPL" internaltype="HTML" winfileextension="tpl" macfileextension="tpl" file="Default.html" writebyteordermark="false">
<TITLE>
<MMString:loadString id="mmdocumenttypes_64" />
</TITLE>
<description>
<MMString:loadString id="mmdocumenttypes_65" />
</description>
</documenttype>



Make sure it is at the end, before the closing tags:

Code:
</documenttypes>


Notice the difference, the extension files are a "documenttype". "</documenttypes>" signals the end of all the document types. Adding anything after this would render the extension useless, and could cause Dreamweaver to behave differently.

Once done, save and close.

Dreamweaver will now recognize the file type.

End note:

Okay, so we are done, Dreamweaver is now happy with a new extension. You can always add more, and define your own styles, and well I may write another tutorial on how to go about doing it. Further, you can always add more than one extension at a time, and it can be limitless.

I hope this helps you guys create templates that much easier, and well do a lot more with Dreamweaver.

Have fun!

Smile

Ionsurge.
----------------------------------------------------
Carlos


Top
 Profile  
Reply with quote  
 Post subject:
PostPosted: Wed Sep 22, 2004 7:13 pm 
Offline
NetHosted Staff
User avatar

Joined: Mon Mar 22, 2004 4:36 pm
Posts: 7373
Thank you for the information I'm sure it'll come in useful for other customers!

Andrew

_________________
| Andrew Bassett
| Managing Director, NetHosted Ltd.
| Earn £30 every time you refer someone to us!
| Follow us on Twitter:
| Members, tell us what of NetHosted!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 9 posts ] 

All times are UTC + 1 hour


Who is online

Users browsing this forum: No registered users and 44 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: