Weblogs at blogs.no-ip.org
you know why you're here !

metadesc.ascx for community server 2008.5


posted by fractalnavel
Thu, Oct 23 2008

Downloads: 54
File size: 2.4kB
Views: 318
metadesc.ascx for community server 2008.5
Filed under: , ,

meta description, keywords and canonical links for site & blog themes.

  • meta descriptions for: weblog, forum and media posts; weblog pages (which are weblog posts); forum  threads; sections, groups and user pages.
  • keywords for: weblog, forum and media posts; weblog pages; and tag pages.
  • canonical links for: weblog, forum and media posts; weblog pages; forum threads.

note that forum posts seem to be getting their keywords from somewhere else already !

adapted from http://dev.communityserver.com/forums/t/500269.aspx, by Alex Crome, with modifications.

  • 2009.06.20: fix for forum post v. thread handling; remove cruft
  • 2009.05.06: added canonical url element for blog, forum and gallery items.
  • 2008.10.24: fixed keyword list rendering from categories / tags.

usage:

site theme:

extract and copy metadesc.ascx to ~/themes/(site theme name)/common

then, in ~/themes/(site theme name)/common/master.master, place

<%@ Register TagPrefix="CSUserControl" 
TagName="MetaDesc" Src="MetaDesc.ascx" %>

with the other @Register's, and place

<CSUserControl:MetaDesc runat="server" />

before <head runat="server">

blog theme (for each theme that you use):

extract and copy metadesc.ascx to ~/themes/blogs/(blog theme name)

then, in ~/themes/blogs/(blog theme name)/theme.master, place

<%@ Register TagPrefix="CSUserControl" 
TagName="MetaDesc" Src="MetaDesc.ascx" %>

with the other @Register's, and place

<CSUserControl:MetaDesc runat="server" />

before <head runat="server">

Add a Comment

(required)
(optional)
(required) 
identicon: ip=38.107.191.93
Please add 3 and 2 and type the answer here:
copyright © 2003-2009, individual posters
Powered by Community Server (Non-Commercial Edition), by Telligent Systems