something like
<xml:template match="Prefs">
<xsl:apply-templates
select="document('lookup.xml')//UPS/pa[(_at_)prefnum=current()/IPS]/*"
mode="p"/>
</xsl:template>
Together with
<xsl:template mode="p" match="*">
<p c="{name()}">
<xsl:apply-templates mode="p"/>
</p>
</xsl:template>
--
http://www.dcarlisle.demon.co.uk/matthew
________________________________________________________________________
This e-mail has been scanned for all viruses by Star Internet. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________
XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list