Portal Engine Questions on portal engine and web parts.
Version 4.x > Portal Engine > How to add meta tag information for a website View modes: 
User avatar
Member
Member
Anuj - 12/15/2009 10:02:26 PM
   
How to add meta tag information for a website
Hello,

I want to add meta tag in my website and also wish to override previously written meta tags. How I could do so?

Thanks in advance...

Regards,
Anuj

User avatar
Member
Member
Alex Rybin - 12/16/2009 6:40:04 AM
   
RE:How to add meta tag information for a website
You can add any tags to header this way
For all the site you should select site's root and then go to "Master Page" tab. There is special text box here where you can add any tags to header of the page.

User avatar
Member
Member
Anuj - 12/16/2009 10:49:57 PM
   
RE:How to add meta tag information for a website
Hi Alex,

Thanks for your reply. But In this way my problem is still same. Now I am able to add new meta tag but there is already some meta tags available in page, I wish to override those tags with some other content.

In this way it is not overriding those contents with my details. So please provide me a solution from which I could override those details.

Regards,
Anuj

User avatar
Member
Member
Alex Rybin - 12/17/2009 12:03:57 AM
   
RE:How to add meta tag information for a website
If you have little C# and ASP.NET knowleges you can make the following.

Please, note, master page layout is classical ASP.NET page, so you can include some server script blocks there. And you can make in this block what your soul wants. :)
Let me show how to make it.


<script runat="server">

protected void pWrapper_Load(object sender, EventArgs e)
{
// Make here some page actions
pWrapper.Visible = false;// Hide our panel for it do not affect page layout
}

</script>

<asp:Panel runat="server" id="pWrapper" OnLoad="pWrapper_Load" />
.... // Other master page layout tags


I do not use Page_Load because it might be used by CMS engine and I do not want to break it.

User avatar
Member
Member
Anuj - 12/29/2009 11:12:41 PM
   
RE:How to add meta tag information for a website
Hello Alex,

Thanks for your reply.

I have a proper knowledge of ASP.NET so I could write codes here. But from this solution I could hide a block from our page but I wish to override my meta tags with some other details. So please tell me that is there any way from which I could change details.

Thanks,
Anuj

User avatar
Member
Member
Alex Rybin - 12/17/2009 12:06:24 AM
   
RE:How to add meta tag information for a website
Another way...

Open you site with MS Visual Studio and open file: /App_Code/Global/CMS/CMSPageEvents.cs.

Here you can add your own code for every of the page events.

User avatar
Kentico Developer
Kentico Developer
kentico_martind - 12/27/2009 6:45:19 AM
   
RE:How to add meta tag information for a website
Hi Anuj,

alternatively you can modify ~/CMSPages/PortalTemplate.aspx template where the default meta tags are generated for pages in Portal Engine. Basically you just need to comment out line "this.ltlTags.Text = this.HeaderTags;" from code-behind of this template (OnPreRender method). Please note that you may need to merge your changes with future versions of this template in future upgrade procedures.

Best Regards,

Martin Dobsicek

User avatar
Member
Member
Anuj - 12/29/2009 11:08:37 PM
   
RE:How to add meta tag information for a website
Hello Martin,

Thanks for the reply but this is increasing my problem coz I don't want to remove all header tags from page. I just want to remove or override meta tags.

So please provide me a convenient way from which I could do it.

Thanks in advance.

Anuj

User avatar
Kentico Developer
Kentico Developer
kentico_ondrejv - 12/30/2009 6:40:13 AM
   
RE:How to add meta tag information for a website
Hello,

Please take a look at following KB article which shows how to parse HEAD elements using standard ASP.NET method:

http://devnet.kentico.com/Knowledge-Base/API-and-Internals/How-to-change-HEAD-tags-in-the-4-x-versions.aspx

I believe it does what you need.

Best regards
Ondrej Vasil

User avatar
Member
Member
wbilaro-yahoo.com - 3/28/2011 7:29:21 AM
   
RE:How to add meta tag information for a website
Hi,

I'm newbie here and we are in the process in implementing Kentico.

From SEO perspective, I just want to know if Kentico supports geo meta tagging and microformats?

If so, is this available as web part or already included in the base license. If not, how do I create one?

Thanks in advance.

Willy

User avatar
Kentico Developer
Kentico Developer
kentico_ondrejv - 3/29/2011 7:05:13 AM
   
RE:How to add meta tag information for a website
Hello,

Well, in general, you can use microformats with no problem using Kentico CMS. It is just about correct HTML/XML markup. This can be done via any Listing/Syndication webpart using its transformation. Details can be found here: http://www.google.com/support/webmasters/bin/answer.py?answer=146897.

Speaking about the microformats markup layout, I find useful the following article: http://www.addedbytes.com/cheat-sheets/microformats-cheat-sheet/.

As for the Geo meta tags, you can add any meta tags to the page either by the Head HTML webpart or directly on the Master page level. Prior to this action, you can generate appropriate Geo meta tags e.g. here: http://www.geo-tag.de/generator/en.html.

Best regards
Ondrej Vasil