xslt how to get value from an xml present as a link(href) in source xml -


i have below code in source file

    <?xml version="1.0" encoding="utf-8"?>     <?dx form=dxmapr4?>     <!doctype map public "-//oasis//dtd dita map//en" "map.dtd"[]>     <map id="docid027853" rev="1" title="an4696" ditaarch:ditaarchversion="1.2"       domains="(topic delay-d)                          (map mapgroup-d)                           (topic indexing-d)                          (map glossref-d)                          (topic hi-d)                           (topic ut-d)                           (topic hazard-d)                          (topic abbrev-d)                          (topic pr-d)                           (topic sw-d)                          (topic ui-d)                         "       class="- map/map " xmlns:ditaarch="http://dita.oasis-open.org/architecture/2005/">       <data name="doctype" value="application note" class="- topic/data "/>       <data name="authorname" value="laura vanzago" class="- topic/data "/>       <topicref type="reference" locktitle="yes" navtitle="@na" toc="no" class="- map/topicref "         href="docid027853_an4696_short_description.dita"/> topicref navtitle="spwf01sx power-up" class="- map/topicref "     href="docid027853_an4696_6_spwf01sxxx_power_up.dita"/>   <topicref navtitle="glossary" class="- map/topicref " href="docid027853_an4696_7_glossary.dita"/>   <topicref navtitle="references" class="- map/topicref "     href="docid027853_an4696_8_references.dita"/>     <map/> 

now want parse xml file present in first topicrefi.e."docid027853_an4696_short_description.dita".

inside file there title tag value want copy in initial source xml. how can that? possible using xslt parse other xml , copy data in source xml?

you can use document() function followed xpath of element want select, e.g. <xsl:value-of select="document(docid027853_an4696_short_description.dita)/thetag"/>.


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

performance - Why is XCHG reg, reg a 3 micro-op instruction on modern Intel architectures? -

jquery - Responsive Navbar with Sub Navbar -