I have a custom module I've written in DNN v4.94 which needs to access a custom host setting. My code is as follows:
Dim HPS As Entities.Portals.PortalSettings
HPS = GetHostPortalSettings()
strHostURL = HPS.HostSettings.Item("HostDomain")
However when I use this in V5.5, I get the warning
"Deprecated in DNN 5.0. Replaced by Host.GetHostSettingsDictionary"
So I try to use Host.GetHostSettingsDictionary using code like this:
strHostURL = DotNetNuke.Entities.Host.Host.GetHostSettingsDictionary("HostDomain")
This time I get the warning
"Replaced in DotNetNuke 5.5 by HostController.GetHostSettingsDictionary()"
So I tried this:
Dim HostCtr As New DotNetNuke.Entities.Controllers.HostController
But get an error:
'DotNetNuke.Entities.Controllers.HostController.Friend Sub New()' is not accessible in this context because it is 'Friend'
I have checked the SuperUser Manual and search DNN (via www.SearchDotNetNuke.com) and can't find any help. Is there a programmers reference guide to DNN V5.5?
Can anyone hlp by showing me an example piece of code for V5.5 just to extract a Host Setting called "HostDomain"?