Localization

Some smaller updates for DbLocalizationProvider

Localization provider is well and alive. Lately I've been heads down busy with porting some of the parts over to .Net Core targeting .Net Standard version 2.0. Anyway just wanted to let you know some of the smaller updates and fixes for the latest version of the provider packages. Multi-Target -> NetFx and Core Now there are specific multi targets for .Net Framework and .Net Core for and packages. This was required due to reported issues when package was used context together with WebApi (to be more specific…

Keep reading

Alternative Localization for Asp.Net Core Applications

Asp.Net Core Built-In Support This is code fragment from official documentation how to localize content using built-in functionality. App Content Localization [Route("api/[controller]")] public class AboutController : Controller { private readonly IStringLocalizer<AboutController> _localizer; public AboutController(IStringLocalizer<AboutController> localizer) { _localizer = localizer; } [HttpGet] public string Get() { return _localizer["About Title"]; } } And if you are working with Html content that shouldn't be escaped during rendering - you are using IHtmlLocalizer implementation that returns LocalizedHtmlString instance. public class BookController : Controller { private readonly IHtmlLocalizer<BookController&…

Keep reading

LocalizationProvider - Tree View, Export and Migrations

It's been a while since last blog post about localization provider. It just means that I've been heads down busy with implementing some great features :) Anyway - these are most probably last features before I'm switching over to .Net Core. I know that you might ask - why you need .Net Core if Episerver is still not there yet!? I'm planning to migrate to .Net Core because Episerver plugin is just small fraction of localization provider and actually you can use it outside of Episerver also - just in regular…

Keep reading

Strongly Localized EPiServer Categories

Initially strongly typed localization provider was not planned to be used everywhere in EPiServer, but localizing categories came as complimentary feature: [LocalizedResource(KeyPrefix = "/categories/")] public class Categories { [ResourceKey("category[@name=\"" + nameof(SampleCategory) + "\"]/description")] public static string SampleCategory => "Some Category !"; } Still there is lot of ceremony to get things right.. Sick and tired of generating proper resource keys for localizing EPiServer categories? Say no more. Localization provider gives you now (within latest version) possibility to decorate your class with attribute…

Keep reading

Feedback Taken - EPiServer Localization Provider Updates

Listen to the audience. I was more than lucky to be on some local user groups to talk about strongly typed localization provider for EPiServer. Feedback from the audience is more likely to be provided than awaiting comments in blog posts. You have to listen to the audience, you really have to. They are your consumers, they know more about the context and projects where and how your library might be used. Over couple of last weeks I've been heads down busy with some of the feedback implementation. Here is…

Keep reading