W3C home > Mailing lists > Public > www-xsl-fo@w3.org > May 2008

Re: Fo-Condition check

From: Saqi <saqib.javed@gmail.com>
Date: Mon, 5 May 2008 09:05:03 +0500
Message-ID: <e43b65bd0805042105m2f8de066r75c3fc87733dfa68@mail.gmail.com>
To: www-xsl-fo@w3.org
Hello Tony Graham
Thanks for your reply.
The car related data is in element form. and my issue is resolved by just
adding this tag
<xsl:if text="car = ''">
<fo:inline color="rgb(255,0,0)" font-family="Arial" font-size="16pt"
          Test
     </fo:inline>
 </xsl:if>


now if there doesn't exist the car related element in xml then this car tag
is omited which was my requirement.
thanks for your help
Regards,
Saqib Javed

On Fri, May 2, 2008 at 4:50 PM, Tony Graham <
Tony.Graham@menteithconsulting.com> wrote:

>
> On Fri, May 02 2008 11:06:24 +0100, saqib.javed@gmail.com wrote:
> > The car related data is simple type of car like Toyota, Honda.........
> > You got my point? if i dont have any data in xml file through i am going
> to
> > populate data using the fo template then it should not give output.
> ...
> >     > if statement
> >     > like
> >     > <xsl:if test="car = '????'">
> >     >     <fo:inline color="rgb(255,0,0)" font-family="Arial"
> font-size="16pt"
> >     >
> >     >          Test
> >     >     </fo:inline>
> >     > </xsl:if>
>
> If you don't show the XML data that you use, then I can only guess at
> how to help you.  I don't even know whether your car data is in an
> element or an attribute.
>
> Please show some XML containing car data and the template rule where you
> want to add the processing of the car data (since the location of the
> car data relative to the context node will affect the XPath expression
> that you would use in your test).
>
> Regards,
>
>
> Tony Graham                         Tony.Graham@MenteithConsulting.com
> Director                                  W3C XSL FO SG Invited Expert
> Menteith Consulting Ltd
> XML, XSL and XSLT consulting, programming and training
> Registered Office: 13 Kelly's Bay Beach, Skerries, Co. Dublin, Ireland
> Registered in Ireland - No. 428599   http://www.menteithconsulting.com
>  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --  --
> xmlroff XSL Formatter                               http://xmlroff.org
> xslide Emacs mode                  http://www.menteith.com/wiki/xslide
> Unicode: A Primer                               urn:isbn:0-7645-4625-2
>
>
Received on Monday, 5 May 2008 04:05:36 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 5 May 2008 04:05:36 GMT