首页 新闻 会员 周边

dom4解析问题

0
[已解决问题] 解决于 2014-07-01 10:01

爆出的错误:

org.dom4j.DocumentExceptionError on line 1 of document  : Content is not allowed in prolog. Nested exception: Content is not allowed in prolog.

 

 

 

代码:

JLGetVehicleInfo.Query(strinformation),

其中 strinformation 是一个字符串如下:

<RequestForm>
<UserID>10009</UserID>
<UserPassWord>zhx2014</UserPassWord>
<RequestItem>1</RequestItem>
<RequestData>
<LicensePlate>测S22333</LicensePlate >
<LicenseColor>2</LicenseColor>
</RequestData>
</RequestForm>

康大头的主页 康大头 | 初学一级 | 园豆:25
提问于:2014-06-30 16:09
< >
分享
最佳答案
1

以前出现过这种情况,是因为格式不对,xml格式中前面部分插入了乱七八糟的文字。你可以再确认下.

奖励园豆:5
angelshelter | 大侠五级 |园豆:9887 | 2014-06-30 16:23
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册