This project is read-only.

Implementing Templates

Sep 14, 2007 at 3:17 PM
u do really amazing job with N2 CMS.

I have a question how to implement ready templates to blank project ... for example:

I download, and
I was extract in some folder, override bin and edit directory and web.config in example project with items from

Now, I want to have for example Search template from implemented in that project.
I was copy N2.Templates.dll and N2.Templates.Search.dll and reference them in example project, and copy Search folder from root of application from

Compile is done without any errors, but when I want to create new item under site root, only Default page is offered to me, I cant see Search item offered....

What I miss?

Thank you.

Sep 14, 2007 at 11:28 PM
The item classes in the template project have parent type constraints in place:

public abstract class AbstractSearch : Templates.Items.AbstractContentPage ...

To allow your page as parent to the search pages you could implement the IStructuralPage interface (it's a marker interface).

Read more about this here

Sep 17, 2007 at 11:42 AM
Thank you Cristian,
thank you for answer .. I am using old templates package 1.2.3. with 1.2.4 example project and doesn't have that interface definition, but procedure it clear now.

BTW. Do u know aprox date when u plan to publish 1.2.4 Templates Package?

Thanks and keep going with good job.

Sep 17, 2007 at 7:33 PM
I'll probably publish a 1.2.5 version any day now. I'll make sure to include a compiled version of the templates.
Sep 18, 2007 at 7:52 AM
Great, thank you very much.