Subject: Re: [xsl] Running xsltproc does not produce any output From: "Piez, Wendell A. (Fed) wendell.piez@xxxxxxxx" <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> Date: Tue, 23 Jul 2024 17:22:39 -0000 |
Jim, nice job. It's good to see the stars aligned on this one (if that's what it is). Regards, Wendell From: ohaya ohaya@xxxxxxxxx <xsl-list-service@xxxxxxxxxxxxxxxxxxxxxx> Sent: Tuesday, July 23, 2024 12:53 PM To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx Cc: ohaya@xxxxxxxxx Subject: Re: [xsl] Running xsltproc does not produce any output Liam, I was able to get your suggested code working with xsltproc.. actually I kind of "enhanced" it a bit... <?xml version="1.0"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:param name="input"/> <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:template match="/syslog"> <xsl:choose> <xsl:when test="string-length($before-tab) = string-length($after-tab)"> <xsl:message>The string-lengths of the string in front of, and after, the [Tab] are THE SAME</xsl:message> <xsl:message> before: <xsl:value-of select="$before-tab" />, after: <xsl:value-of select="$after-tab" />. </xsl:message> </xsl:when> <xsl:otherwise> <xsl:message>The string-lengths of the string in front of, and after, the [Tab] are NOT THE SAME</xsl:message> <xsl:message> before: <xsl:value-of select="$before-tab" />, after: <xsl:value-of select="$after-tab" />. </xsl:message> </xsl:otherwise> </xsl:choose> </xsl:template> </xsl:stylesheet> and I test with xsltproc: xsltproc -o foo --stringparam input 'Command=Password$[Tab]Password$;' initialparsetest.xsl auditrecord.xml and: xsltproc -o foo --stringparam input 'Command=Password$[TabXXXXX]Password$;' initialparsetest.xsl auditrecord.xml I am going to make a new post/thread about how I want to go forward after this. Thanks! Jim XSL-List info and archive<http://www.mulberrytech.com/xsl/xsl-list> EasyUnsubscribe<http://lists.mulberrytech.com/unsub/xsl-list/3302254> (by email<>)
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
Re: [xsl] Running xsltproc does not, ohaya ohaya@xxxxxxxx | Thread | Re: [xsl] Running xsltproc does not, ohaya ohaya@xxxxxxxx |
Re: [xsl] Running xsltproc does not, ohaya ohaya@xxxxxxxx | Date | Re: [xsl] Running xsltproc does not, Liam R. E. Quin liam |
Month |