我对使用XML有疑问。我使用XML作为数据存储库。我想使用XML来存储带变量的句子,内部元素是变量(php),一旦被检索,它将被php值/变量替换。
我想知道这是否正确使用带动态变量的XML?或者是否存在另一种存储此类数据的选项?
以下是一个例子:
<argument-scheme
xmlns:xsi="http://www.w3.org/2001/XMLSchema"
xmlns:schemaLocation="G:\EasyPHP-DevServer-14.1VC11\data\localweb\argupedia\frontend\arg-scheme-repository\arg-scheme.xsd"
id='0'
name='Argument from Sign'
>
<premise> $paramArray[0] is true in this situation.</premise>
<premise> $paramArray[1] is generally indicated as true when its sign, $paramArray[0] is true, in this kind of situation."</premise>
<conclusion>Therefore, $paramArray[1] is true in this situation.</conclusion>
<critical-question>"Is the correlation between " . $paramArray[0] . " and " . $paramArray[1] . "strong?"</critical-question>
<critical-question>Is $paramArray[0] the only event that reliably account for $paramArray[1] ?</critical-question>
<param-name>Sign</param-name>
<param-name>Conclusion</param-name>
<param-question>What is the observation?</param-question>
<param-question>What is the conclusion that can be drawn from the observation</param-question>
</argument-scheme>
以下是如何使用xml的示例: