For DotNetNuke Administrators
PortalSkinHelper offers a perfect solution for a decade-long struggle.
Most DotNetNuke modules, especially complex ones, need to navigate between different module controls. For instance, adding events in Flex Events uses AddEvent control, while managing bookings uses another control.The easiest way to jump to another control is to use DotNetNuke.Entities.Modules.PortalModuleBase.EditUrl method, which redirects the end user to another page in a simple, reliable, and consistent way.
DotNetNuke supports two types of skins, portal skin and admin skin. Portal skin is used when a visitor browse your website, and edit skin is used when DotNetNuke consider you are editing the content of your website. The major problem of using EditUrl is DotNetNuke always uses the admin skin for URLs generated by EditUrl. Some website use same skin as portal skin and admin skin. In this case using EditUrl does not contribute to any noticable problem.. As a consequence, DNN might properly loads the portal skin on a page, but it loads the admin skin when a module navigates to a different control.
Many solutions were proposed to fix this solution in the laste dacade, but none of them is perfect. When we were working on Flex Events 2.0 development, we encountered this problem, and we found a solution to fix it. Our solution only requires a lightweight httpmodule to be installed in your web.config by clicking a button. It also allows you to manage a supported module list. We also decided to offer this solution to the DotNetNuke community for free.
Visit our website, www.bizmodules.net, to download a free copy of PortalSkinHelper. Once installed, you can find an Config.xml file in /desktopmodules/portalskinhelper folder, which maintains the supported module list. If you wish to apply this feature to any DNN module, just add its name to the supported module list.
Summing up, PortalSkinHelper forces DotNetNuke to use portal skin instead of edit skin for URLs generated by DotNetNuke.Entities.Modules.PortalModuleBase.EditUrl method.
For DotNetNuke Module Vendors
Since anyone can download PortalSkinHelper for free, all DotNukNuke module vendors can potentially benefit from this module. You can use EditUrl in your module as you wish. If the client use same skin as portal skin and admin skin, then everything is fine. On the other hand, if the client use different skins, you can easily fix their problems by telling them to install PortalSkinHelper.
It is also a good idea to provide a "include" file for PortalSkinHelper. A "include" file is an XML file which includes a list of module names that can be added to PortalSkinHelper's supported module list, and it should be copied to /desktopmodules/portalskinhelper folder when your own module is installed. For example, The installable package of Flex Events contains an "include" file, Include_FlexEvents.xml, which will be copied to /desktopmodules/portalskinhelper folder when Flex Events is installed. When PortalSkinHelper runs, it automatically detects this file(actually, it scans for Include_*.xml), read the supported module list, and merge them to its own supported module list.
To copy your include file when own module is being installed, include this node in your module definition(.dnn) - packages - package - components:
The format of the "include" file should be like this:
<module name="FlexEvents" />
When the include file is offered, your module will be in the supported module list once PortalSkinHelper is installed and enabled. As a comparision, your end users will be required to manually add your module name to the supported module list after installing and enabling PortalSkinHelper if the include file is not offered.
Though PortalSkinHelper is free, our license does not allow module vendors to redistribute PortalSkinHelper. Unlike Flex Events, you cannot install PortalSkinHelper automatically as a part of your own module. Contact us by email if you wish to get a redistributable license.
PortalSkinHelper can be downloaded in our Downloads page. Please remember you have to register and login first to see all available downloads.