Subject: Re: [xsl] Why doesn test work in one case, but not another??? From: didoss@xxxxxxxxxxx Date: Wed, 10 May 2006 19:20:42 +0000 |
Sorry, I'm new to this, so I can't speak much to your logic, but the one that doesn't work has an extra namespace defined,...maybe you are getting some sort of conflict? -------------- Original message ---------------------- From: Shirley Gasch <sgasch@xxxxxxxxxxxxxxxxxxxxx> > Hi, > > I am using XML Version 1 and have two situations of search results > pages. In one, a test between a text variable in Filemaker Pro and a > text value works perfectly, but in another, it doesn't. > Unfortunately, I can't see what is different about them. I have > included the front part from both and the test areas from both: > > Works: > > Front Part: > > <?xml version="1.0" encoding="ISO-8859-1"?> > <?xslt-cwp-query param="-grammar=fmresultset"?> > <xsl:stylesheet version="1.0" > xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > xmlns:fmrs="http://www.filemaker.com/xml/fmresultset" > xmlns:fmq="http://www.filemaker.com/xml/query" > xmlns:fmxslt="xalan://com.fmi.xslt.ExtensionFunctions" > exclude-result-prefixes="xsl fmrs fmq fmxslt"> > > <xsl:import href="cdml2xsl_includes.xsl"/> > <xsl:variable name="_errorcode" > select="/fmrs:fmresultset/fmrs:error/@code"/> > <xsl:variable name="token.error" > select="$request-query/fmq:query/fmq:parameter[@name = > '-token.error']"/> > <xsl:variable name="token.errnum" > select="$request-query/fmq:query/fmq:parameter[@name = > '-token.errnum']"/> > > <xsl:param name="authenticated-xml-base-uri"/> > <xsl:param name="request-query"/> > <xsl:variable name="current-max"><xsl:call-template > name="get-current-max"/></xsl:variable> > <xsl:variable name="current-skip"><xsl:call-template > name="get-current-skip"/></xsl:variable> > <xsl:variable name="link-first"><xsl:call-template > name="get-link-first"/></xsl:variable> > <xsl:variable name="row-count"><xsl:value-of > select="/fmrs:fmresultset/fmrs:resultset/@count"/></xsl:variable> > <xsl:variable name="link-last"><xsl:call-template > name="get-link-last"/></xsl:variable> > <xsl:variable name="link-next"><xsl:call-template > name="get-link-next"/></xsl:variable> > <xsl:variable name="link-previous"><xsl:call-template > name="get-link-previous"/></xsl:variable> > <xsl:output method="html" encoding="ISO-8859-1"/> > > <xsl:template match="/fmrs:fmresultset"> > Test Portion: > > <td valign="top" headers="chgappl"> > <p><b>MSM: </b><xsl:value-of > select="$record/fmrs:field[@name = 'MSMApproval']/fmrs:data[1]"/><br/> > <xsl:value-of > select="$record/fmrs:field[@name = > 'MSMDate']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > <xsl:choose><xsl:when > test="'MssnTer' = 'Y'"> > <b>Terra MD: > </b><xsl:value-of select="$record/fmrs:field[@name = > 'MDApproval']/fmrs:data[1]"/><br/> > <xsl:value-of > select="$record/fmrs:field[@name = 'MDDate']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > </xsl:when><xsl:otherwise> > <xsl:choose><xsl:when > test="'MDApproval' != ''"> > <b>Terra MD: > </b><xsl:value-of select="$record/fmrs:field[@name = > 'MDApproval']/fmrs:data[1]"/><br/> > <xsl:value-of > select="$record/fmrs:field[@name = 'MDDate']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > > </xsl:when></xsl:choose> > </xsl:otherwise></xsl:choose> > <xsl:choose><xsl:when test="'MssnAqu' = 'Y'"> > <b>Aqua MD: </b><xsl:value-of > select="$record/fmrs:field[@name = > 'AqMDApproval']/fmrs:data[1]"/><br/> > <xsl:value-of select="$record/fmrs:field[@name = > 'AqMDDate']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > > /xsl:when></xsl:choose> > <xsl:choose><xsl:when test="'MssnAur' = 'Y'"> > <b>Aura MD: </b><xsl:value-of > select="$record/fmrs:field[@name = > 'AuMDApproval']/fmrs:data[1]"/><br/> > <xsl:value-of > select="$record/fmrs:field[@name = > 'AuMDDate']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > > </xsl:when></xsl:choose><b>MM: </b><xsl:value-of > select="$record/fmrs:field[@name = 'MMApproval']/fmrs:data[1]"/><br/> > <xsl:value-of select="$record/fmrs:field[@name = > 'MMDate']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > <xsl:choose><xsl:when test="'MssnLnch' = 'Y'"> > <b>Launch MM: </b><xsl:value-of > select="$record/fmrs:field[@name = > 'LnchMMApproval']/fmrs:data[1]"/><br/> > <xsl:value-of select="$record/fmrs:field[@name = > 'LnchMMDate']/fmrs:data[1]"/> > <xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text></xsl:when><xsl:otherwise> > <xsl:choose><xsl:when test="'LnchMMApproval' != ''"> > <b>Launch MM: </b><xsl:value-of > select="$record/fmrs:field[@name = > 'LnchMMApproval']/fmrs:data[1]"/><br/> > <xsl:value-of select="$record/fmrs:field[@name = > 'LnchMMDate']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text> > </xsl:when></xsl:choose> > </xsl:otherwise></xsl:choose><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text></p> > > Doesn't Work: > > Front Part: > > <?xml version="1.0" encoding="ISO-8859-1"?> > <?xslt-cwp-query param="-grammar=fmresultset"?> > <xsl:stylesheet version="1.0" > xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > xmlns:fmrs="http://www.filemaker.com/xml/fmresultset" > xmlns:fml="http://www.filemaker.com/fmpxmllayout" > xmlns:fmq="http://www.filemaker.com/xml/query" > xmlns:fmxslt="xalan://com.fmi.xslt.ExtensionFunctions" > exclude-result-prefixes="xsl fmrs fml fmq fmxslt"> > > > <xsl:import href="cdml2xsl_utilities.xsl"/> > <xsl:param name="authenticated-xml-base-uri"/> > <xsl:param name="request-query"/> > <xsl:variable name="_errorcode" > select="/fmrs:fmresultset/fmrs:error/@code"/> > <xsl:variable name="token.error" > select="$request-query/fmq:query/fmq:parameter[@name = > '-token.error']"/> > <xsl:variable name="token.errnum" > select="$request-query/fmq:query/fmq:parameter[@name = > '-token.errnum']"/> > > <xsl:variable name="current-max"><xsl:call-template > name="get-current-max"/></xsl:variable> > <xsl:variable name="current-skip"><xsl:call-template > name="get-current-skip"/></xsl:variable> > <xsl:variable name="link-first"><xsl:call-template > name="get-link-first"/></xsl:variable> > <xsl:variable name="row-count"><xsl:value-of > select="/fmrs:fmresultset/fmrs:resultset/@count"/></xsl:variable> > <xsl:variable name="link-last"><xsl:call-template > name="get-link-last"/></xsl:variable> > <xsl:variable name="link-next"><xsl:call-template > name="get-link-next"/></xsl:variable> > <xsl:variable name="link-previous"><xsl:call-template > name="get-link-previous"/></xsl:variable> > <xsl:output method="html" encoding="ISO-8859-1"/> > > <xsl:template match="/fmrs:fmresultset"> > > Test Portion: > <td valign="top" width="10%"> > <xsl:choose><xsl:when test="'System' = 'A'"> > <b>System A: </b><xsl:value-of > select="$record/fmrs:field[@name = > 'SysANode']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > > </xsl:when></xsl:choose> > <xsl:choose><xsl:when test="'System' = 'B'"> > <b>System B: </b><xsl:value-of > select="$record/fmrs:field[@name = > 'SysBNode']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > > </xsl:when></xsl:choose> > <xsl:choose><xsl:when test="'System' = 'Ground Stations'"> > b>GS: </b><xsl:value-of > select="$record/fmrs:field[@name = 'GSNode']/fmrs:data[1]"/><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text><br/> > > </xsl:when></xsl:choose> > <xsl:choose><xsl:when test="'System' = 'AT Server'"> > <b><xsl:text disable-output-escaping="yes">At > Server:&nbsp;</xsl:text></b><br/> > > </xsl:when></xsl:choose><xsl:text > disable-output-escaping="yes">&nbsp;</xsl:text> > </td> > > Note: In all of these cases, the variables are defined only in Filemaker Pro. > > I have studied both of these examples, but don't see why one works > and one doesn't!!! Any suggestions??? > > Shirley Gasch > -- > Shirley Gasch Phone: (301) 794-2164 > Computer Sciences Corporation Fax: (301) 794-8355 > 7700 Hubble Drive, Rm N384 > Lanham/Seabrook, Md. 20706 email: sgasch@xxxxxxx
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Why doesn test work in on, Shirley Gasch | Thread | [xsl] Sort an xml file by the using, Jagsmiles |
RE: [xsl] Namespace-aliasing and ex, Buchcik, Kasimier | Date | RE: [xsl] Namespace-aliasing and ex, Michael Kay |
Month |