Simple Styling of EPiServer Forms

Prior to EPiServer Forms 4.5, we were forced to inject in our own styling by editing the less files. This often resulted in breaking functionality where javascript were dependant upon these base CSS classes. EPiServer last year changed this by binding javascript to data attributes freeing us from styling shackles. This article is for thoseContinue reading “Simple Styling of EPiServer Forms”

EPiServer Forms – Quick Start

I was asked once by a client to build some functionality that allowed editors to create forms on the fly without developer effort. EPiServer did the work for us. Here’s an overview on Forms. Out of the box EPiServer Forms boast the following form elements ready to use: Text, Text Area, Number, DateTime, Range, Url,Continue reading “EPiServer Forms – Quick Start”

EPiServer Find Index – unknown property

This particular nugget has screwed with me for a few days. When attempting to run a standard EPiServer Find index, my log files were getting flooded with this: An exception occurred while indexing (Content): MapperParsingException[failed to parse [Blocks.Items.Blocks.Items.DefaultPrice.UnitPrice.Currency]]; nested: ElasticSearchIllegalArgumentException[unknown property [CurrencyCode$$string]]; . Contact episerver support to get them to move your index to aContinue reading “EPiServer Find Index – unknown property”

EPiServer 10 – Restrict any Block Types on XHtmlString property using the Validation Attribute

I couldn’t find a similar solution online as I believe there is an emerging pattern where we are now instructing clients to drag EPiServer Blocks into Rich Text editors. Requirement: As an Editor I want to limit certain blocks types from being dragged into the rich text editor Solution #1: Apply this attribute to anyContinue reading “EPiServer 10 – Restrict any Block Types on XHtmlString property using the Validation Attribute”

EPiServer 7.5 – Exception – More than one content model is assigned to the guid

When running an EPiServer site and you get the exception “More than one content model is assigned to the guid”. This is usually because you’ve changed a namespace. There will be a reference to the old namespace cached somewhere so do the following: 1) Clear your bin folder 2) Clear the ASP.NET Temporary files folderContinue reading “EPiServer 7.5 – Exception – More than one content model is assigned to the guid”

New Marie Curie ‘In Your Area’ Search Functionality

For the past two weeks here at Marie Curie we’ve been working on new functionality for searching for Marie Curie services across the United Kingdom. It has just today finally gone live and now we can serve our supporters with better information about the key services and events in their area. ‘In Your Area’ OnContinue reading “New Marie Curie ‘In Your Area’ Search Functionality”

Property Injection & Action Filters in EPiServer 7 CMS

I spent a bit of time putting in some custom implementation to support Property Injection on to my Action Filters before realizing that EPiServer 7 already provides this functionality for me. Doh. In order to take advantage all you need to do is set your DI controlled interface to the generic type property of the Injected class.Continue reading “Property Injection & Action Filters in EPiServer 7 CMS”

Manipulating an EPiServer Page Programmatically

Creating a Page Here’s how you can create a page in code from a page type you’ve already defined. First create a new instance of the page type under another page in the form of a link: var newBlogPost = ContentRepository.GetDefault<BlogPostPage>(parentLink); Then set whatever properties you wish to the newBlogPost object. newBlogPost.Subject = “Creating an EPiServerContinue reading “Manipulating an EPiServer Page Programmatically”

EPiServer 7 CMS – Import and Exporting Content between Environments

At Marie Curie we have several environments that sit across our infrastructure. Occasionally we get a requirement to shift content from one environment to another. This could be because we’ve auto generated pages via scheduled job or that QA have created a string of pages and want it replicated in another environment without having to key themContinue reading “EPiServer 7 CMS – Import and Exporting Content between Environments”