turquoiseowl / i18n

Smart internationalization for ASP.NET
Other
556 stars 155 forks source link

where is i18n.LanguageHelpers.ParseAndTranslate? #410

Closed mrsuau627 closed 3 years ago

mrsuau627 commented 3 years ago

We've been using your i18n library for about a month or so and have had very good luck so far. Now we've come across the need to do some translations serverside that are not directly related to the HttpContext (sending emails, translating a "report" that gets saved as a file, etc). Looking at the documentation, in the "How to get a translation of a nugget in your C# code" section, there's an example of this which says to use

string entity = i18n.LanguageHelpers.ParseAndTranslate("[[[Thank you for your payment]]]");.

However, when I try to access i18n.LanguageHelpers, the ParseAndTranslate method does not exist.

Has it been removed from LanguageHelpers? If so, is there a different way to perform a translation server-side when an HttpContext is not available? I would also need to set the language to translate to at that point as well.

Thanks!

turquoiseowl commented 3 years ago

It was added recently to the current master branch but not yet released on NuGet.

I'll try to get a new release on NuGet this week that includes it.

mrsuau627 commented 3 years ago

It was added recently to the current master branch but not yet released on NuGet.

I'll try to get a new release on NuGet this week that includes it.

That explains it. We look forward to it. Thanks!

mrsuau627 commented 3 years ago

Can close this issue now because ParseAndTranslate is in the latest release via NuGet