Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...DNN 5 Skins - link to a tabDNN 5 Skins - link to a tab
Previous
 
Next
New Post
1/26/2012 11:29 AM
 

Hi,

 I would like to add few links to various tabs from my skin and found this blog post by John Mitchell:

http://blogs.snapsis.com/CommentView,...

Just wanted to know if this the best way to acheive this or are there any better SEO friendly options available.

Regards
Arif Shah

 
New Post
1/26/2012 1:41 PM
 

Yes, there are better ways to do that now (SEO wise).

Add this code to your ASCX skin:

<script runat="server" language="vb">
           
    Private Function GetPageLinkByName(ByVal PageName As String) As String
        
        Dim oTabC As New DotNetNuke.Entities.Tabs.TabController
        Dim oTab As DotNetNuke.Entities.Tabs.TabInfo = oTabC.GetTabByName(PageName, PortalSettings.PortalId)
        If Not oTab Is Nothing Then
            Return String.Format("<a href='{0}'>{1}</a>", oTab.FullUrl, PageName)
        Else
            Return ""
        End If
                
    End Function
    
</script>

 Then add this to your skin:

<%= GetPageLinkByName("Contact")%>

Of each link.
This used to be case sensitive, I think before DNN 5.3, but not anymore.

HTH

 
New Post
1/27/2012 8:45 AM
 

Thank very much. It works like a charm.

 Regards
Arif Shah

 
Previous
 
Next
HomeHomeUsing DNN Platf...Using DNN Platf...Skins, Themes, ...Skins, Themes, ...DNN 5 Skins - link to a tabDNN 5 Skins - link to a tab


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out