Robert<br>Try moving it all inside the first template:<br><br><xsl:template match="/rules">     <br>  <!-- put it here --><br></xsl:template><br><br>Alternatively invert it.  So that you have:<br>
<br><xsl:variable ...><br>  <xsl:choose><br>  ...<br></xsl:variable><br><br>although this means that the conditions will be repeated for each of bllat, bllon, trlat, trlon which is ugly.<br><br>Etienne<br>
<br><br><div><span class="gmail_quote">On 9/17/06, <b class="gmail_sendername">Robert Hart</b> <<a href="mailto:Robert.Hart@burohappold.com">Robert.Hart@burohappold.com</a>> wrote:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>> Something like this ought to work:<br>><br>> <xsl:choose><br>>  <xsl:when test='/rules/@bllat'><br>>     <xsl:variable name='bllat'><value-of select='/rules/@bllat'/><br>>     <xsl:variable name='blllon'><value-of select='/rules/@bllon'/>
<br>>     ...<br>>   </xsl:when><br>>   <xsl:when test='$data/osm/@bllat'><br>>     <xsl:variable name='bllat'><value-of select='$data/@bllat'/><br>>     <xsl:variable name='blllon'><value-of select='$data/@bllon'/>
<br>>    ...<br>>   </xsl:when><br>>   <xsl:otherwise'><br>>     <!-- existing code for bllat bllon etc goes here --><br>>   </xsl:otherwise><br>> </xsl:choose><br><br><br><br>
You'd think so wouldn't you. Would appear you can't have an xsl:choose as a<br>top-level element though. *sigh* will have to think some more.<br><br>Rob<br><br><br><br><br><br><br>Rob<br><<ouputbbox.diff>>  <<
osmarender.xsl >><br><br><br><br>_______________________________________________<br>dev mailing list<br><a href="mailto:dev@openstreetmap.org">dev@openstreetmap.org</a> <mailto:<a href="mailto:dev@openstreetmap.org">
dev@openstreetmap.org</a>><br> <<a href="http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev">http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev</a>><br><a href="http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev">
http://lists.openstreetmap.org/cgi-bin/mailman/listinfo/dev</a><br><br><br><br><br><br><br><br><br>This message has been scanned for viruses by MailControl - <a href="http://www.mailcontrol.com">www.mailcontrol.com</a><br>
</blockquote></div><br>