2015-11-04 91 views
0

很容易標記單個內容,然後將其作爲xml在inDesign中導出。如何標記inDesign文檔以使標記的內容位於其他標記之間?

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> 
<Root><content>Simple text block</content></Root> 

我正在努力做的是讓它將標籤/內容導出到另一組標籤中。 例如:我想標記我的文檔,以便它導出爲這樣:

<?xml version='1.0' encoding='UTF-8'?> 
<article> 
    <id>123</id> 
    <content> 
    <body>Some text</body> 
    <headline>Some other text</headline> 
    </content> 
</article> 

這裏是我的嘗試: enter image description here

當我出口我得到了以下的XML:

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> 
<article> 
    <content>Simple text block</content> 
    <id>123</id> 
    <content></content> 
    <body>Some text</body> 
    <headline>Some other text</headline> 
</article> 

如何標記元素以便將標籤/內容導出到另一組標籤中?

回答

2

我認爲你需要使用結構面板(視圖 - >結構 - >顯示結構)。

將根目錄重命名爲「文章」添加標識和內容標籤,並將主體和標題添加到內容標籤。

標記佈局對象並嘗試導出xml。

+0

非常感謝你 – grabury