Following Update .properties file with values from .xml file I have the following problems:
Problem 1: Example: X.xml:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE DOC SYSTEM "ts.dtd">
<?xml-stylesheet type="text/css" href="ts.css"?>
<DOC>
<PTXT ID="a.b.c.d" CONTEXT="label"><NTI>Text</NTI></PTXT>
</DOC>
Y.properties:
a.b.c.d=Text
and my output is:
a.b.c.d=
Text=
=
Can you please help me as I really don't understand what's going on.
Problem 2: Example: X.xml
my.id = \u00D6ffnen Express WebTools
and Y.properties
<PTXT ID="my.id" CONTEXT="">Öffnen <NTI>Express WebTools</NTI></PTXT>
results in: out.properties
my.id=Öffnen Express WebTools
my.id=\u00D6ffnen Express WebTools
instead of
my.id=Öffnen Express WebTools
Update
- All my files contains nested NTI, no NTI and text with nested NTI combined.
I cannot join string that ends with = as janos suggested because my output is something like:
first.id= second.id=Text from second id Text from first id= I don't know what's wrong with stackoverflow but it seems that it's not seeing my code as code....