Moving strings containing HTML tag to resource files

I want to move some UI lines into resource files. The lines contain some style tags like: "I want to move this < i >string< / i >

to resource files".

What's the best way to do this? If possible, please provide an example with code?

PS: - 1) Breaking the line into 3 parts is not an option as it makes the translation hard.

2) I tried using: - @string.Format(Resources.ResourceString, string)

. Where ResourceString

= I want to move this < i >{0}< / i >

to resource files.


source to share

1 answer

It is quite common to include HTML formatting in localized string resources and translators (as well as the CAT tools used by translators) are generally knowledgeable about basic HTML and will store your HTML tags in translations. Although, of course, you should check that your localized strings are in order when you receive your translations and as part of your QA plans.

As you said, splitting lines can cause more problems for the translator than keeping them the same with their HTML tags.



All Articles