Hi,

I’m writing a small demo and I’ve use Alain’s wikipedia example with a few mods 
to return the “snippet”  from the search data. Code below :-

                <xf:instance xmlns="" id="query">
                <data>
                <action>query</action>
                <list>search</list>
                <srprop>snippet</srprop>
                <srsearch>llama</srsearch>
                <format>json</format>
                <sroffset>0</sroffset>
                <srlimit>20</srlimit>
                </data>
                </xf:instance>
  
                <xf:submission id="search"  method="get" replace="instance"  
mode="synchronous"
                instance="results" ref="instance('query')" 
action="http://en.wikipedia.org/w/api.php"; mediatype="text/jsonp">
                </xf:submission>
  
In the results I get encoded html in each snippet like so:

    <search exsi:maxOccurs="unbounded">
            <ns xsi:type="xsd:double"/>
            <title>Llama firearms</title>
            <snippet>&lt;span class='searchmatch'&gt;Llama&lt;/span&gt; 
Firearms officially known as &lt;span 
class='searchmatch'&gt;Llama-&lt;/span&gt;Gabilondo y Cia SA was a Spanish arms 
company founded in 1904 under the name Gabilondo and Urresti 
&lt;b&gt;...&lt;/b&gt;</snippet>
        </search>
   
What I want to do is spit this out in my xf:repeat using 

<xf:output value="snippet" mediatype="text/html"/>

But it doesn’t work. It renders it as a string. So what am I doing wrong?


Rgds,

Mark Lawson
Senior Technical Architect
Staffordshire and West Midlands Probation Trust
[email protected]
[sent from home email]



------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
Xsltforms-support mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xsltforms-support

Reply via email to