开发者

Is that kind of structure allowed in XML?

开发者 https://www.devze.com 2023-02-20 12:55 出处:网络
Is that kind of structure allowed in XML ? <category> <pattern>ANSWER MY QUESTION</pattern>

Is that kind of structure allowed in XML ?

<category>
    <pattern>ANSWER MY QUESTION</pattern>
    <template>
        Please try asking 
        <set name="it">y开发者_运维百科our question</set> 
        another way.
    </template>   
</category>


Yes, it's perfectly valid. In XML Schema parlance, it's known as the "mixed content" model.

Whether or not it's a good idea, however, is another question entirely.


Why wouldn't it be? XML can be anything you as long as it's properly formatted, and that looks properly formatted as far as I'm concerned.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号