AnsweredAssumed Answered

xml parse exception.........

Question asked by spillai on Jan 5, 2008
Latest reply on Jul 22, 2008 by harmaildhiman

I am trying to process a xml document like the one given below,

  <?xml version="1.0" encoding="UTF-8" ?>
  <mstns:CommonQuestion xmlns:mstns="" xmlns:alf="" xmlns:chiba="" xmlns:ev="" xmlns:xf="" xmlns:xhtml="" xmlns:xs="" xmlns:xsi="">
  <mstns:Question>this is question 1<br /></mstns:Question>
  <mstns:Answer>this is answer 1</mstns:Answer>
  <mstns:Keywords>key1 key2 key3</mstns:Keywords>

with the template file as given below :

<#ftl ns_prefixes={"mstns":""}>
<#list resultset as node>
         <td><#if node.mimetype ="text/xml">
                     <#assign dom=node.xmlNodeModel>

using the reference from :
and the post on forum at :

but on execution of the webscript it throws the following error:

Message:   Error during processing of the template 'Expression .vars["mstns:CommonQuestion/mstns:Question"] is undefined on line 7, column 36 in com/medicalert/XmlFileFinder/xmlFileSearcher.get.html.ftl.'. Please contact your system administrator.

Exception:   freemarker.core.InvalidReferenceException - Expression .vars["mstns:CommonQuestion/mstns:Question"] is undefined on line 7, column 36 in com/medicalert/XmlFileFinder/xmlFileSearcher.get.html.ftl.

Please help me out……..

Sujay Pillai