Recent Posts
None | 1 sec ago
None | 14 sec ago
None | 23 sec ago
None | 34 sec ago
None | 35 sec ago
Java | 55 sec ago
XML | 56 sec ago
None | 1 min ago
What is pastebin?
Pastebin is a website that hosts all your text & code on dedicated servers for easy sharing.
learn more...
Domain Reports
By mdata on the 7th of Aug 2009 03:39:19 AM
Download |
Raw |
Embed |
Report
<%@ Control language="vb" AutoEventWireup="false" Explicit="True" Inherits="DotNetNuke.UI.Skins.Skin" %>
<asp:placeholder id="SkinPlaceholder" runat="server">
<link rel="stylesheet" type="text/css" id="csslink" runat="server" />
<div id="ControlPanel" runat="server" />
<div id="ContentPane" runat="server" class="ContentPane Pane" />
</asp:placeholder>
Private Sub Page_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
'** Skincovered.com Portal Alias based skin switcher
'** Switches the skin depending on the Url used to access the site
'** Select this skin (topmenu_switch) as would any other skin in DotNetNuke
'** The code below will load a skin from the same folder depending on the Url
Dim skin As String = ""
Dim HostName As String = Request.ServerVariables("SERVER_NAME").ToLower()
Select HostName.Remove(HostName.IndexOf("."))
Case "foo":
skin = "foo"
Case "bar":
skin = "bar"
Case Else:
'this skin will be loaded if no matches were made to the portal aliases above
skin = "default"
End Select
'this line loads the actual skin.
Dim sc As Control = LoadControl(skin+".ascx")
SkinPlaceholder.Controls.Remove(ControlPanel)
SkinPlaceholder.Controls.Remove(ContentPane)
SkinPlaceholder.Controls.Add(sc)
csslink.Attributes.Add("href", SkinPath+skin+".css")
End Sub
Submit a correction or amendment below.
Make A New Post