我正在尝试设计一个带有页脚菜单的皮肤,并在 tabID 方面取得了一些成功。但是,如果其他人使用该皮肤,选项卡 ID 会发生变化。
如何设置我的页脚菜单以接收名为“页脚”的页面的所有子项?我在页面列表中只有一个“页脚”页面,它包含 T&C、联系方式、隐私政策等。
我正在尝试设计一个带有页脚菜单的皮肤,并在 tabID 方面取得了一些成功。但是,如果其他人使用该皮肤,选项卡 ID 会发生变化。
如何设置我的页脚菜单以接收名为“页脚”的页面的所有子项?我在页面列表中只有一个“页脚”页面,它包含 T&C、联系方式、隐私政策等。
您可以按如下方式获取TabInfo
选项卡,然后使用该Footer
选项访问所有选项Tab's props
,例如 TabID,...
var tabInfo = DotNetNuke.Entities.Tabs.TabController.Instance.GetTabByName("Footer", PortalId);
var footerPageTabId = tabInfo.TabID;
// work with footerPageTabId ...
After checking the documentation again, I realized there's a nodeselector option for "TabName" which I missed.
Using <dnn .. .. . ..NodeSelector='footer'>
worked for me.
Another option would be the poster above's method where global variables are populated with the tabID and called with NodeSelector='<%# TabName %>'