Blogs posted in 2015
Creating an Episerver Nuget Feed Explorer
For a while I've wanted to explore the Episerver Nuget Feed in a little more detail than was available on the standard http://nuget.episerver.com page. For example I would like to filter by community submitted versus Episerver packages and also know when packages have been updated and/or submitted, in particular recently updated or added packages. So I decided to put a an Episerver Nuget Feed Explorer tool together that allows users to look at the data available on the Episerver Nuget feed, filter it and facet it:
MenuPin v3.2 released - click and hold to unpin/hide everything
A new version of MenuPin for EPiServer 9 is now available on the EPiServer Nuget feed.
What's new in v3.2
A new gesture has been added to the pin. When the top menu is pinned out, click and hold the pin to unpin the top menu and hide the left and right hand side items. This allows users to quickly get back to a clear view when items have been pinned out in the UI:
Enabling the new projects feature in EPiServer
Update
As of EPiServer Update 87 which released EPiServer.CMS.Core 9.3 and EPiServer.CMS.UI 9.3 the projects feature is now out of beta there is no need to add users to the EPiBetaUsers group
This a quick "note to self" on how to enable the new projects feature in the later versions EPiServer (8+ and 9 at the time of writing) as I constantly forget how to do it.
Once enabled editors get access to the projects feature that includes the project bar at the bottom of the UI as shown below:
MenuPin v3.1 released - instantly hide the menu on unpin
A new version of MenuPin for EPiServer 9 is now available on the EPiServer Nuget feed.
MenuPin for EPiServer 9 released
A new version of MenuPin is now available. This is is a compatibility release for EPiServer 9 upwards. If you have not heard of MenuPin before then it allows users to pin the menu at the top of the EPiServer UI (as shown in the image).
What's new in v3.0:
- Compatible with EPiServer 9+
Cookie Drop Block for EPiServer
Previously I blogged about Cookie visitor group criteria for EPiServer. This visitor group criteria allows editors to check the values of cookies or simply that they exist. Today the "Cookie Drop Block" for EPiServer is released. It allows editors to create a block, that when rendered drops a cookie for the user.
Cookie visitor group criteria for EPiServer
Two new visitor groups called "Cookie exists" and "Cookie Value Equals" have been released. These visitor groups allow your site editors to personalise content based on whether a cookie exists or on the value contained within a cookie.
MenuPin v2.2 for EPiServer released
A new version of MenuPin for EPiServer 8 is now available on the EPiServer Nuget feed.
What's new in v2.2
In previous versions pinning or unpinning the menu meant the entire page was refreshed. Version 2.2 means the menu can be pinned without the need to refresh the entire page:
Restricting the total number of items in an EPiServer media folder
EPiServer gives our users a tremendous amount of power and flexibility. However users can occasionally do things that may affect performance or their experience of EPiServer. One of these things is adding a large number of images/documents into a folder in the media library. By adding too many items to a folder the folder not only becomes cumbersome to browse and use but can also affect performance in extreme circumstances.
MenuPin v2.1 for EPiServer 8 released
A new version of MenuPin for EPiServer 8 is now available on the EPiServer Nuget feed.
What's new in v2.1
Without using MenuPin clicking the globe by default takes you to view the selected page in the tree:
However when using MenuPin v2.0 clicking the globe icon took you to the site homepage. MenuPin v2.1 makes the globe icon at the top work in the same way as the globe on the pull down menu and takes you to view the selected page.
Creating a custom promotion with the new EPiServer Commerce 9 promotion engine (BETA) - Part 2
In my previous post I desribed how to programmatically create a custom promotion in EPiServer Commerce 9 beta. The post was developer focussed and showed how we can create custom promotions/discounts in EPiServer 9 than previously possible. In this post I will contrate on the experience of our editors and merchandisers as we want them to see something nice in the UI when working in their campaigns than a forms view right?
Creating a custom promotion with the new EPiServer Commerce 9 promotion engine (BETA) - Part 1
The latest version of EPiServer Commerce (v8.13.4 at the time of writing) has an all new promotion engine that is currently in beta. The best part about the new engine is that the EPiServer Commerce 9 promotion engine is designed to be more developer friendly and extensible than the previous one.
This post is a quick example of how we can build a custom promotion with the new EPiServer Commerce promotion engine.
Update to the “Useful EPiServer Dojo links” post
I have previously blogged about Useful EPiServer Dojo links that contains a useful list of Dojo examples in for EPiServer.
Recently I have noticed a lot of new posts talking about Dojo in EPiServer and how it can be used to make modifications to the EPiServer UI or create custom properties. So this is a post to let people know that I updated my original post with many more links to useful posts and examples including a new "Spotted in the forums" section.
Working with the EPiServer Projects API
EPiServer Projects is one of the key new features in the EPiServer Spring 2015 release. It gives editors the ability to add content items to a project then preview any changes as if they were published. Projects not only allow editors to preview content before its published but can also serve as a useful navigation device to group a set of changes together for editors to work on.
For example editors may need to work on projects such as when a set of articles need to be reviewed or a monthly commerce catalog update. So as developers we may want to programmatically create projects to help editors rather than letting editors manually create them.
This post explores how to use the EPiServer Projects API.
Visitor group usage viewer for EPiServer 8
EPiServer visitor groups are a great feature and allow editors to personalise content for end users. EPiServer also has the capability for editors to preview content for certain visitor groups when viewing a page. This is a powerful capability as editors can see how the content will look when its been personalised for end users. However when a lot of visitor groups are enabled on a site its sometimes difficult for editors to work out which ones are used on a piece of content and to pick the right visitor groups to preview with.
So I decided to create a visitor group usage gadget that will help editors see what visitor groups are used on piece of content in EPiServer.
Setting the EPiServer connection string programmatically
A customer asked if it was possible to set the database connection string programmatically in an EPiServer site. In the customer's specific example they wanted to use a configuration database rather than store any configuration in a .config file.
This can be achieved by creating a custom IDatabaseFactory implementation that allows you to set the connection string programmatically:
MenuPin for EPiServer 8 released
A new version of MenuPin is now available. This is is a compatibility release for EPiServer 8 upwards. If you have not heard of MenuPin before then it allows users to pin the menu at the top of the EPiServer UI (as shown in the image).
What's new in v2.0:
- Compatible with EPiServer 8+
- Its now available as a standard Nuget package on the EPiServer Nuget feed (its no longer an Add-on)
PriceEvents v1.1 for EPiServer Commerce released
Update
As of EPiServer Commerce 8.15 Price events are now available in the core product. More information: http://world.episerver.com/blogs/Quan-Mai/Dates/2015/7/new-events-for-price-and-inventory-updates/
A new version of PriceEvents has been released with some minor ammendments.
What's new in v1.1
- The PriceChanged event is now broadcast after the data has been saved to keep the semantics on the event name correct
- A new PriceDeleting event is available to notify of any price deletions
Enabling events for price changes in EPiServer Commerce
Update
As of EPiServer Commerce 8.15 Price events are now available in the core product. More information: http://world.episerver.com/blogs/Quan-Mai/Dates/2015/7/new-events-for-price-and-inventory-updates/
When developing a EPiServer Commerce solution it may be necessary to listen for events that let us know pricing has changed. By default EPiServer Commerce does not broadcast an event when prices change so I wanted to put a solution together that allowed developers to subscribe to events in a similar way that we can for content events in EPiServer.
So what use does this have? I can think of a number of uses where listening to events on pricing may be useful:
- Logging - Prices are sensitive and you can use price save events to log who changed the prices
- Indexing - If you are using a tool such as EPiServer Find you may be indexing price information with your product data. The price events allow you to re-index individual items as soon as the price as changed
- Integration - You may wish to kick off a process or send a message to an external system as soon a price changes
Claims helper block for EPiServer
This post describes a simple claims helper block I put together. This block can come in useful if you are using federated authentication and would like to inspect all claims for the current user.
I created this whilst developing the solution for implementing federated security in EPiServer using Auth0.
Allowing users to log in to the EPiServer UI with Auth0
In my previous post I described how its possible to implement federated security in EPiServer using Auth0. However the steps described on allow users to log into your site with Auth0. It's not possible to log into the EPiServer UI using the described steps. The post describes how to extend the implementation to allow users logging in via Auth0 to use the EPiServer UI.
This is due to the fact that when using federated security EPiServer respects the http://schemas.microsoft.com/ws/2008/06/identity/claims/role claim to check access rights. However many providers do not issue these claims so we need an Auth0 rule to create some roles then do a little work in EPiServer to map them into http://schemas.microsoft.com/ws/2008/06/identity/claims/role claims.
Implementing federated security in EPiServer using Auth0
This post describes how to allow federated security in EPiServer using Auth0. Auth0 is an identity broker that's extensible, enterprise class and reduces the friction between identity infrastructure and developers. I'm not affiliated with Auth0 in any way so this post is written from my own (admittedly very good) experience with Auth0. The post contains a number of step by step instructions and is intended to be an example on how to use Auth0 with EPiServer. The original demo was presented in November 2014 at the EPiServer UK customer and partner day.
EPiServer debugging tools
This is a quick post about some useful debugging tools available when working on custom development within an EPiServer site. Per Bjurstrom has already blogged about EPiServer 7: Startup Performance. This revealed the URL "/<episerverUI>/Shell/Debug/ShowTimeMeters" which helps you look up how long your initialisation modules take to load.