Subject: Re: [xsl] Running xsltproc does not produce any output From: "Liam R. E. Quin liam@xxxxxxxxxxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> Date: Tue, 23 Jul 2024 03:59:01 -0000 |
On Tue, 2024-07-23 at 03:01 +0000, ohaya ohaya@xxxxxxxxx wrote: > B > I am starting to look into what needs to be done (Note this might be > a little off-topic)... > > First, reminder, the <ExtraDatails> has like: > > Command=Password$[Tab]Password$;ConnectionComponentId=Users;DstHost=m > y.solutions;Protocol=NC;ID=Server_W01;SessionID=0c97ce2e-c0a2-467d- > 952e- > e1b81a9a5149;SrcHost=xx.zz.0.24;TXTOffset=1593B;User=xxxxx;VIDOffset= > 39T; > > and I want to detect where the 2 password strings are the same > length, and if they are, then I will want to check if the 2 strings > are identical... > > So I first need to check if the length of string in front of the > [Tab] is the same the length of the string after the [Tab], before > the semi-colon So, <xsl:variable name="before-tab" select=" substring-before( substring-after($input, '='), '[Tab]' ) " /> <xsl:variable name="after-tab" select=" substring-before( substring-after($input, '[Tab]'), ';' ) " /> <xsl:if test="string-length($before-tab) = string-length($after-tab)"> <xsl:message>The robots are coming</xsl:message> </xsl:if> You can also do, <xsl:message> before: <xsl:value-of select="$before-tab" />, after: <xsl:value=of select="$after-tab" />. </xsl:message> If by [Tab] you mean a tab charcter, use  in your XSLT, not a literal tab character (and not \t as that does not work in XSLT). liam -- Liam Quin,B https://www.delightfulcomputing.com/ Available for XML/Document/Information Architecture/XSLT/ XSL/XQuery/Web/Text Processing/A11Y training, work & consulting. Barefoot Web-slave, antique illustrations: B http://www.fromoldbooks.org
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Running xsltproc does not, ohaya ohaya@xxxxxxxx | Thread | Re: [xsl] Running xsltproc does not, Liam R. E. Quin liam |
Re: [xsl] Running xsltproc does not, ohaya ohaya@xxxxxxxx | Date | Re: [xsl] Running xsltproc does not, Liam R. E. Quin liam |
Month |