Thread: ASP.NET/DNN some useful links

DNN some useful links

Using the DNN 6 Form Pattern


www.mitchelsellers.com/blogs/2011/12/19/getting-up-to-speed-on-dnn-6x-design.aspx





Re: DNN some useful links

NavigateURL: How to make A DotNetNuke® link (in VB and C#)


www.adefwebserver.com/dotnetnukehelp/NavigateURL/





Re: DNN some useful links

How to use the Globals.NavigateUrl DNN method by any portal



int portalId = 0; // Specify any valid portal id

PortalSettings portalSettings = new PortalSettings(portalId);
// Specify a portal alias that was not initialized by the constructor
PortalAliasController portalAliasController = new PortalAliasController();
ArrayList aliases = portalAliasController.GetPortalAliasArrayByPortalID(portalId);
portalSettings.PortalAlias = aliases[0] as PortalAliasInfo;

TabController tabController = new TabController();
TabCollection tabs = tabController.GetTabsByPortal(portalId);

List<string> localeCodes = new List<string>();

foreach (string languageCode in Localization.GetLocales(portalId).Keys)
localeCodes.Add(languageCode);

foreach (TabInfo tab in tabs.Values)
{
   foreach (string locale in localeCodes)
    {
         string friendlyUrl = DotNetNuke.Common.Globals.NavigateURL(tab.TabID, tab.IsSuperTab, portalSettings, String.Empty, locale);
    }
   }
}