Home

Creating a hierarchal menu in EPiServer

By Johan Pettersson 20 August 2010 16:44

Lately I’ve seen different ways of creating a menu with correct and semantic html in EPiServer. The example in the EPiServer SDK is just soooo wrong from most perspectives. I think this is the best and simplest way:

Read more...

Seo tip: canonical domain

By Johan Pettersson 24 April 2010 13:46

One really big enhancement is canonical urls for your/customers content. I’m sure you all know about the problem with duplicated content, but not everyone tend to fix it. Here’s my take on it.

Read more...

Posted in EPiServerTags

PermalinkComments (0)

Country custom property

By Johan Pettersson 11 April 2010 17:51

Give your editors the possibility to select a country from a drop down list.

Read more...

Always check if e.Page is null in DataFactory events

By Johan Pettersson 14 January 2010 11:03

If you’re listening to DataFactory events like:

protected void Application_Start(object sender, EventArgs e)
{
    EPiServer.DataFactory.Instance.CreatingPage 
        += new EPiServer.PageEventHandler(CreatingOrSavingPage);

    EPiServer.DataFactory.Instance.SavingPage
        += new EPiServer.PageEventHandler(CreatingOrSavingPage);
}

Always check if Page is null in PageEventsArgs. If we're copying a page in edit mode the Page will be null in one of the events!

I've updated the code for my dynamic content fix, check on line 3 in CreatingOrSavingPage.

Posted in EPiServerTags

PermalinkComments (0)

How to set a page updated programmatically

By Johan Pettersson 13 January 2010 17:43

If you want to mimic the “Mark page as changed”-checkbox in code it's not so obvious how to do that.

Read more...

Posted in EPiServerTags

PermalinkComments (0)

Browse by

Tags

Dates

2010
August (1)
April (2)
January (2)
2009
December (4)
November (2)
October (1)