To reference an image in your themes folder for your custom skin, follow the steps below:
- Make sure that your ASCX file inherits from the DotNetNuke.UI.Skins.Skin namespace by using the following code:
<%@ Control language="c#" AutoEventWireup="false" Explicit="True" Inherits="DotNetNuke.UI.Skins.Skin"
%> - Use
<%=SkinPath%>
to correctly reference the image path to its respective theme location. Please see an example ASCX file below:
<%@ Control language="c#" AutoEventWireup="false" Explicit="True" Inherits="DotNetNuke.UI.Skins.Skin"
%> <li> <a class="logo" href="https://www.website.com"> <img src="<%=SkinPath%>test.png" alt="testlogo" title="Test Logo"> </a> </li>
Comments
0 comments
Please sign in to leave a comment.