阅读背景:

xml中出现“文档中根元素后面的标记必须格式正确。”的错误_Mr_Pang的专栏_文档中根元素后面的标记必须格式正确。

来源:互联网 
出现这个错误的原因是,没有加根节点。请看下面的代码:
<?xml version="1.0" encoding="GB2312" standalone="no"?>
<time>//如果这里和结尾的</time>不加,就会出现如题的错误
<monday>
	<playGameTime>5.0</playGameTime>
	<studyTime>3.0</studyTime>
	<readTechnologyTime>0.0</readTechnologyTime>
	<officialTime>0.0</officialTime>
	<otherTime>0.0</otherTime>
	<efficiency>0.0</efficiency>
	<state>ok</state>
</monday><tuesday>
	<playGameTime>5.0</playGameTime>
	<studyTime>3.0</studyTime>
	<readTechnologyTime>0.0</readTechnologyTime>
	<officialTime>0.0</officialTime>
	<otherTime>0.0</otherTime>
	<efficiency>0.0</efficiency>
	<state>ok</state>
</tuesday>
</time><?xml version="1.0



你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: