Skip to main content
Participant
July 22, 2009
Answered

How do i package a DW extension?

  • July 22, 2009
  • 1 reply
  • 4546 views

Hi all

I have created an Insert Object extension (or at least i have tried) for DW CS4, however i have no idea of how to package it and make it appear in the insert bar.

In other words, i have created the HTML, JS and icon files - what is next? How do i make it an installable package, so that a new insertbar is added and the buttons are displayed?

Thanks in advance.

This topic has been closed for replies.
Correct answer pziecina

Okay, that solved the insert-bar problem, but the menu is still like on the screendump


In your 'head' you have -

<macromedia-extension
         name="Joomla! 1.5 Template Builder"
         version="1.0.0"
         requires-restart="true"
         type="insertbar">

The 'type' is the default location for the item, it then takes the name of the htm(l) file, which in your case is 'if'.

Your mxi file is not showing the append to code (example in the mxi_file_format.pdf last item), my example is -

<menu-insert appendTo="Joomla">
<menuitem id="DWMenu_Insert" name="If" file="if.htm" />

</menu-insert>

PZ

1 reply

pziecina
Legend
July 22, 2009

Out of necessity this reply may appear to be a little unclear, it is not intended so.

If you do not have the sdk for developing extension then you can get it here - http://www.adobe.com/cfusion/exchange/index.cfm?event=extensionDetail&extid=1009962 , do not worry that it says DW8, and you will get warnings that items are placed in other places, the extension must also be installed by selecting 'run as administrator' when starting the extension manager in vista, (a new version of the sdk is in development).

After installing the extension go to the dreamweaver program folder (not the users), and you will find a folder called SDK, inside this folder the docs folder contains a folder with file inside, both called, MXI file format, The code for creating an extension (example of), is contained within this pdf file, (first item).

If you get stuck with any item or code for this, please feel free to ask for clarification.

PZ

b1tsAuthor
Participant
July 22, 2009

Thanks alot! That got me some of the way, however i cant quite make it function.

 

This is my .mxi:

 

.mxi
<macromedia-extension
         name="Joomla! 1.5 Template Builder"
         version="1.0.0"
         requires-restart="true"
         type="insertbar">
     <author name="(removed) , inFront Media" />
     <products>
         <product name="Dreamweaver" version="8" primary="true" required="true"/>
     </products>
     <description>
         <![CDATA[This extension is a template tool assisting the implementation of Joomla! 1.5 templates.]]>
     </description>
     <ui-access>
         <![CDATA[Access the tool by selection Insert > Joomla!.]]>
     </ui-access>
     <files>
         <file
             source="if.htm"
             destination="$Dreamweaver/Configuration/Objects/Joomla"
             shared="false" />
         <file
             source="if.js"
             destination="$Dreamweaver/Configuration/Objects/Joomla"
             shared="false" />
     </files>
     <configuration-changes>
         <menu-insert appendTo="DWMenu_Insert">
             <menu id="DWMenu_Insert_Joomla" name="Joomla">
                 <menuitem name="If" file="if.htm" id="DWMenu_Insert_Joomla_If" />
                 <separator />
             </menu>
         </menu-insert>
         <insertbar-changes>
             <insertbar-insert pretendTo="DW_Insertbar">
                 <category folder="Joomla!" id="DW_Insertbar_Joomla">
                     <button file="if.htm" id="DW_Insertbar_Joomla_If" image="if.gif" />
                 </category>
             </insertbar-insert>
         </insertbar-changes>
     </configuration-changes>
</macromedia-extension>

 

All i want is a submenu in the Insert menu containing the parent "Joomla" and the sub "If" referring to the functionality of if.htm, and accordingly a Joomla bar in the Insert bar with the button "If".

 

What is the problem here?

 

The above code gives a parent menu in the Insert menu "Joomla" but no sub elements. instead the If Menu is displayed under the Parent Joomla as a parent iten (see screenshot). The Insertbar doesnt appear.

pziecina
Legend
July 22, 2009

As near as I can see (sorry, I have broken my glasses ), you are using two separate names for the menu name.

  1. <![CDATA[Access the tool by selection Insert > Joomla!.]]>
  2. <menu id="DWMenu_Insert_Joomla" name="Joomla">

One has a ! on the end, the other does not.

PZ