我在导入xliff文件时遇到了一些奇怪的问题。我的代码中的一些情节提要字符串和字符串都没有导入,即使它们在xliff文件中也是如此。
下面是我的xliff:
<body>
<trans-unit id="Athenticate for login">
<source>Athenticate for login</source>
<note>No comment provided by engineer.</note>
<target>Autentisering for innlogging</target>
</trans-unit>
<trans-unit id="Attempts left: ">
<source>Attempts left:</source>
<note>No comment provided by engineer.</note>
<target>Forsøk igjen: </target>
</trans-unit>
<trans-unit id="Wrong PIN-code. Try again">
<source>Wrong PIN-code. Try again</source>
<note>Message displayed when user enter wrong PIN-code</note>
<target>Feil PIN kode. Forsøk igjen</target>
</trans-unit>
</body>这是我的localizable.strings
/* No comment provided by engineer. */
"Athenticate for login" = "Autentisering for innlogging";
/* Message displayed when user enter wrong PIN-code */
"Wrong PIN-code. Try again" = "Feil PIN kode. Forsøk igjen";如你所见,“剩余的尝试”被省略了……
有人知道为什么吗?(情节提要中的一些字符串也被省略了)
谢谢..。
发布于 2016-01-07 16:25:47
问题可能是在您的XLIFF中,“尝试左”的ID和源文本是不同的: ID有一个尾随空格,源文本已经在冒号之后结束。尝试向XLIFF源内容添加一个空间,然后查看导入是否有效。
https://stackoverflow.com/questions/34645150
复制相似问题