Last week we at Geta released a new version of the 404 handler.
Last week we at Geta released a new version of the 404 handler.
Previously, I wrote an article how to create a Razor view engine which supports feature folders. This view engine had one drawback.
Choosing proper dependency injection type might be hard. But it is not so hard when you have a recipe.
Jacob Khan has written an article how to preview content in a View Mode. While this works fine, it ignores visitor groups.
Several months ago I wrote an article about UI testing basics in Episerver. This is more practical article how to implement these basic principles using canopy testing framework.
Time to time I am getting an issue with DDS mapping mismatch. In this article, I will show the possible solutions.
The most of the Episerver Commerce project examples (for example, Quicksilver) are using cookies to store selected market. The URL doesn't change which can cause several SEO issues. Crawlers are not able to index market specific content. If the market info could be included in the URL, it would solve most of these problems.
Recently, Episerver has changed relation APIs. Now those are easier to understand and use.
Recently Episerver released Commerce 11. It contains a new feature - a product sorting. But unfortunately, there is no way to sort categories.
A few months ago I created a library which enabled Razor views in Episerver Shell modules. Now Episerver has built support for it by default.
When importing data into Episerver - CMS or Commerce, it is a common task to upload images. In this article I will show how to do it from the remote URL.
A few months ago I wrote an article about better event handling. Now I have created and published a library which allows you to handle Episerver events in this way easier.
Last week I was working on the custom user interface for customer management and discovered two useful tips which help to work with customers in Episerver.
When you have multiple environments - for production, staging, and testing, there is a need to copy over production environment data to staging and testing environments. In Episerver this is quite easy - just copy over database and blobs. But you have to update Episerver website configuration to match your staging/test environment setup. You have to change website URL and add hostnames for your new environment. This can be done in a user interface, but it is better to automate.
Episerver has preview functionality available in edit mode. It did not satisfy our customer. The customer wanted to see the page as it will be displayed when get published. But I found that Episerver has "hidden" feature which enables you to display concrete commerce content version.
Recently I was configuring a CDN in Azure for one of our projects. We needed to serve most of the static content (images and scripts) from the CDN to improve page load times. After the CDN had been set up, I had to change the content URLs to point to the CDN. There are several options to do it. You might handle it directly in the code, rewrite all URLs in some handler or as I did with URL rewrite.
When creating Episerver modules, you need a common layout for your pages. You can find different examples of Web Forms layout for Episerver modules, but as now with Geta's shell razor support package it is possible to create Razor views, you need a Razor layout.
Recently, I was creating a library package for Episerver and required to create a NuGet package. Usually, at Geta we have a Team City configuration for project builds and NuGet package creation. But this time I was creating my package. While it is possible just to package your project with nuget.exe directly, it would need too many manual steps when releasing a new version of your package. In this article, I will show how to use FAKE for this purpose.
Last week I had a requirement to implement a manual order discount which can be set on any cart by the administrator/editor. I found that there is a manual discount for line items in the Commerce Manager and found how to use those in my code. When I tried to implement it the same way for the order discount, then it didn't work. The order discount requires a different approach which is described in this article.
In the article Better event handling in Episerver, I wrote how to handle Episerver events. I was calling the async Publish method of mediator in the fire and forget manner. But it is not a good solution in an ASP.NET application as there is no warranty that the running task will finish.
Two weeks ago I wrote an article how to enable Razor views in Episerver modules. Now we created and published a module which does it for you.
I haven't done UI testing much as I found it quite unreliable, hardly maintainable and hard to write. But there are still some cases when it is useful to have some UI tests.
I have not created an Episerver module before. When I started on one last week, I found that there are no examples with Razor views. After looking and trying to create a module, concluded that it even doesn't support Razor views by default. But I figured out one way which works.
Previously, I wrote an article how to handle events in the Episerver but I did not show how to test those. I am a fan of the Test Driven Development but when working with the Episerver it is quite hard to test the code including .NET event testing. Developers tend to not write unit tests for those. In this article, I will show that this is quite easy when using the right tools.
Usually, when importing or updating categories, products or variations I have published those immediately and never had any issues. But recently had an issue when a customer wanted to publish updated products manually. I had to save those without publishing but didn't get anything saved - at least no info was visible in the UI.
In January I wrote an article which documented Episerver content events. As it was seen from this article, there are plenty of events available and those have different event arguments with different properties where not all of those properties are used. This makes the API hard to use.
There are some resources available which explain how to configure razor view engine to support feature folders. But most of these resources describe how to do it in an ordinary MVC project. Episerver projects have some limitations which I took into account in this article. This article also covers a sub-folder support.
Almost a year ago I wrote an article about feature folders vs tech folders. I explained why you should favor feature folders vs tech folders. While I see this style of architecture more and more, I also see that developers use tech folders inside feature folders. In this article, I am going to describe alternatives to this type of structure.
There are times when you need to be notified about some actions happening in the Episerver and execute the code when it happens. Episerver has built-in events which help to achieve it. In this article, I will describe content events which are implemented through IContentEvents interface.
In the last article, I did not mention Initialization Modules. Those also do not support a constructor injection but Initialization Modules are different.