OrchardCMS / Orchard

Orchard is a free, open source, community-focused Content Management System built on the ASP.NET MVC platform.
https://orchardproject.net
BSD 3-Clause "New" or "Revised" License
2.37k stars 1.12k forks source link

Orchard.Localization 1.x RuleEngine bugs #4949

Open orchardbot opened 9 years ago

orchardbot commented 9 years ago

thims created: https://orchard.codeplex.com/workitem/21120

Parser in Scripting prevents using the "-" character in token names. So, all culture-xxx rules are unusable. Renaming is needed in CultureRuleProvider.cs. For example, "culture-lang" has to be "culturelang" or something similar. ProcessCultureId() in CultureRuleProvider.cs is actually a copy-paste of ProcessCultureCode(). What you really need is to compare c.Name with currentUserCulture.LCID.ToString().

orchardbot commented 9 years ago

@jetski5822 commented:

Thanks - I fixed number 1.

Have you an example of number 2?