Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...DNN Platform (o...DNN Platform (o...Can you put more than one module in a package?Can you put more than one module in a package?
Previous
 
Next
New Post
8/7/2009 4:46 PM
 

I'll start this by saying that I am very new to DNN, but have been spending the better part of the last week trying to figure this out doing my due diligence before asking ...

We're developing a website for a customer and knowing that we will have many custom modules, I was thinking I might be able to package them all into a single version 5 package file and install the whole set together.   This is all with 5.1.1 of DNN.

I've seen lots of websites that imply that this is possible, but everyone always shows example with one module in the package.   I tried creating two modules and putting them in a package.   Things immediately fell apart because, for some reason, the Friendly Name of the package was being used when adding each of the modules to the database, and then an exception in the portal was occuring because the Friendly Names of the two modules were the same.    I dug around and found that the Friendly Name is indeed assigned to the Package.FriendlyName in DotNetNuke.Services.Installer.Installers.ReadManifest.   It seems like the FriendlyName under the ModuleDefinition isn't even used.   

So, my question is ... has anyone done this before?   I can't be the first to try.    Yes, I could go and create a package for my SqlDataProvider class, and then a package/module for every one of my modules, but that seems silly given the structure of the DNN package manifest.    I tried looking in the bug tracking system but couldn't find anything there either.

Thanks for any help anyone might have.

-mike

 
New Post
8/7/2009 10:38 PM
 

You should be able to add an additional package node and have them install fine together. I haven't tried it myself, but it does look like it would work.

Can you post how your dnn file is structured?

 
 
New Post
8/7/2009 11:17 PM
Accepted Answer 

Hey Mike,

I just tested this out, and it does in fact work. Up until now I had just assumed it works and I hadn't actually put more than one module in an installation package.

You'll need to organize all modules into one package with two package nodes. This means you'll need to gather all of your relevant files into one single directory. This could impact file naming conventions depending on how you organize things. I suggest using the "Resources.zip" approach to help minimize file name conflicts between bundled modules.

I just installed a package that had two package elements. Each were of type module. Only the first package went through the installation "wizard" - the second package was just installed straight up. So if you have any release notes or license information or company information - make sure you include that with the first package.

In my example, the first module is Engage: Tell A Friend. The second module is Engage: To Do (a module we use in our training classes). The Tell A Friend module uses the "Resources.zip" approach, whereas the To Do module explicitly lists all of its files in the manifest. You can see that here:

<dotnetnuke type="Package" version="5.0">

  <packages>

    <package name="Engage: Tell A Friend" type="Module" version="01.01.00">

      <friendlyName>Engage: Tell A Friend</friendlyName>

      <description>A simple and flexible module for sharing DNN websites from Engage Software (http://www.engagesoftware.com/).</description>

      <owner>

        <name>Engage Software</name>

        <organization>Engage Software</organization>

        <url><![CDATA[<a href="http://www.engagesoftware.com/">http://www.engagesoftware.com/</a>]]></url>

        <email><![CDATA[<a href="mailto:support@engagemodules.com">support@engagemodules.com</a>]]></email>

      </owner>

      <license src="TAFEULA-Free.htm"/>

      <releaseNotes src="TAFReleaseNotes_1.1.0.htm" />

      <components>

        <component type="ResourceFile">

          <resourceFiles>

            <basePath>DesktopModules/EngageTellAFriend</basePath>

            <resourceFile>

              <name>TAFResources.zip</name>

            </resourceFile>

          </resourceFiles>

        </component>

        <component type="Module">

          <desktopModule>

            <moduleName>Engage.TellAFriend</moduleName>

            <foldername>EngageTellAFriend</foldername>

            <businessControllerClass>Engage.Dnn.TellAFriend.FeaturesController</businessControllerClass>

            <moduleDefinitions>

              <moduleDefinition>

                <friendlyName>EngageTellAFriend</friendlyName>

                <defaultCacheTime>0</defaultCacheTime>

                <moduleControls>

                  <moduleControl>

                    <controlKey/>

                    <controlSrc>DesktopModules/EngageTellAFriend/ViewTellAFriend.ascx</controlSrc>

                    <controlType>View</controlType>

                  </moduleControl>

                  <moduleControl>

                    <controlKey>Settings</controlKey>

                    <controlSrc>DesktopModules/EngageTellAFriend/Settings.ascx</controlSrc>

                    <controlType>Edit</controlType>

                  </moduleControl>

                </moduleControls>

              </moduleDefinition>

            </moduleDefinitions>

          </desktopModule>

        </component>

        <component type="Assembly">

          <assemblies>

            <assembly>

              <name>EngageTellAFriend.dll</name>

              <version>01.01.00</version>

            </assembly>

          </assemblies>

        </component>

        <component type="Script">

          <scripts>

            <basePath>DesktopModules/EngageTellAFriend</basePath>

            <script type="UnInstall">

              <name>TAFUnInstall.SqlDataProvider</name>

              <version>01.01.00</version>

            </script>

          </scripts>

        </component>

      </components>

    </package>

    <package name="EngageTellAFriend" type="SkinObject" version="1.0.0">

      <friendlyName>Engage: Tell A Friend Skin Object</friendlyName>

      <description>A simple and flexible skin object for sharing DNN websites from Engage Software (http://www.engagesoftware.com/).</description>

      <owner>

        <name>Engage Software</name>

        <organization>Engage Software</organization>

        <url><![CDATA[<a href="http://www.engagesoftware.com/">http://www.engagesoftware.com/</a>]]></url>

        <email><![CDATA[<a href="mailto:support@engagemodules.com">support@engagemodules.com</a>]]></email>

      </owner>

      <components>

        <component type="SkinObject">

          <moduleControl>

            <controlKey>EngageTellAFriend</controlKey>

            <controlSrc>DesktopModules/EngageTellAFriend/ViewTellAFriend.ascx</controlSrc>

          </moduleControl>

        </component>

      </components>

    </package>

    <package name="Engage: To Do" type="Module" version="1.0.0">

      <friendlyName>Engage: To Do</friendlyName>

      <description>A DotNetNuke Module from Engage Software</description>

      <owner>

        <name />

        <organization />

        <url />

        <email />

      </owner>

      <license>The license for this package is not currently included within the installation file, please check with the vendor for full license details.</license>

      <releaseNotes />

      <components>

        <component type="Module">

          <desktopModule>

            <moduleName>Engage: To Do</moduleName>

            <foldername>EngageToDo</foldername>

            <businessControllerClass>Engage.Dnn.ToDo.FeatureController</businessControllerClass>

            <supportedFeatures />

            <moduleDefinitions>

              <moduleDefinition>

                <friendlyName>ToDo</friendlyName>

                <defaultCacheTime>0</defaultCacheTime>

                <moduleControls>

                  <moduleControl>

                    <controlKey />

                    <controlSrc>DesktopModules/EngageToDo/ViewTasks.ascx</controlSrc>

                    <supportsPartialRendering>False</supportsPartialRendering>

                    <controlTitle />

                    <controlType>View</controlType>

                    <iconFile />

                    <helpUrl />

                    <viewOrder>0</viewOrder>

                  </moduleControl>

                  <moduleControl>

                    <controlKey>Edit</controlKey>

                    <controlSrc>DesktopModules/EngageToDo/AddTask.ascx</controlSrc>

                    <supportsPartialRendering>False</supportsPartialRendering>

                    <controlTitle>Add Task</controlTitle>

                    <controlType>Edit</controlType>

                    <iconFile />

                    <helpUrl />

                    <viewOrder>0</viewOrder>

                  </moduleControl>

                  <moduleControl>

                    <controlKey>Settings</controlKey>

                    <controlSrc>DesktopModules/EngageToDo/ToDoSettings.ascx</controlSrc>

                    <supportsPartialRendering>False</supportsPartialRendering>

                    <controlTitle>ToDo Settings</controlTitle>

                    <controlType>Edit</controlType>

                    <iconFile />

                    <helpUrl />

                    <viewOrder>0</viewOrder>

                  </moduleControl>

                </moduleControls>

              </moduleDefinition>

            </moduleDefinitions>

          </desktopModule>

        </component>

        <component type="Assembly">

          <assemblies>

            <basePath>bin</basePath>

            <assembly>

              <name>EngageToDo.dll</name>

            </assembly>

          </assemblies>

        </component>

        <component type="File">

          <files>

            <basePath>DesktopModules\EngageToDo</basePath>

            <file>

              <path>App_LocalResources</path>

              <name>AddTask.ascx.resx</name>

            </file>

            <file>

              <path>App_LocalResources</path>

              <name>Settings.ascx.resx</name>

            </file>

            <file>

              <path>App_LocalResources</path>

              <name>ViewTasks.ascx.resx</name>

            </file>

            <file>

              <name>AddTask.ascx</name>

            </file>

            <file>

              <name>module.css</name>

            </file>

            <file>

              <name>Settings.ascx</name>

            </file>

            <file>

              <name>ViewTasks.ascx</name>

            </file>

          </files>

        </component>

      </components>

    </package>

  </packages>

</dotnetnuke>

The file structure in my zip was as follows:

  • App_LocalResources (Used by the ToDo Module)
    • AddTask.ascx.resx
    • Settings.ascx.resx
    • ViewTasks.ascx.resx
  • bin (Used by both modules)
    • EngageTellAFriend.dll
    • EngageToDo.dll
  • AddTask.ascx (Used by the ToDo module)
  • EngageToDoAFriend.dnn (The combination manifest file. The initial naming was innocent. Leaving it as such may not have been ;)
  • module.css (Used by the ToDo module)
  • Settings.ascx (Used by the ToDo module)
  • TAFEULA-Free.htm (Used by the TAF module)
  • TAFReleaseNotes_1.1.0.htm (Used by the TAF module)
  • TAFResources.zip (Used by the TAF module, holds all ascx, resx, images, css, etc.. and is just straight up unpacked in the desktopmodules\EngageTellAFriend directory)
  • TAFUnInstall.SqlDataProvider (Used by the TAF module)
  • ViewTasks.ascx (Used by the ToDo module)

There are certainly better ways to organize the files - this is kind of a messy hodgepodge - but it does work!

Also, based on the issues you were running in to - i'd suggest you make sure you use different friendly names for your modules. As you saw - that doesn't work out so well. :)

Hope that helps,

Ian


Software Engineer
Co-Founder, dnnGallery
Stack Overflow: Ian Robinson
Twitter: @irobinson
Linked In: Ian Robinson
 
New Post
8/8/2009 1:42 PM
 

Oh hell ... I can't believe I didn't think to try that one.   As you suggested, I split the two modules under one package to 2 packages with one module each in the same file.   Worked like a charm!    Not exactly what I'd consider the most intuitive implementation, but hey, if it works, then I can move on with my life.

Thanks!

-mike

 
Previous
 
Next
HomeHomeDevelopment and...Development and...DNN Platform (o...DNN Platform (o...Can you put more than one module in a package?Can you put more than one module in a package?


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out