Subject: Re: XT: Output current users' login and full name? From: "Pete Johnston" <P.Johnston@xxxxxxxxxxxxxxxxxx> Date: Fri, 13 Aug 1999 14:55:58 GMT |
[Kai Grossjohann] > Our DTD contains an empty element `doccreator', and I would like the > output to contain the login and full name of the user running XT. I'm > using Makefiles in a Unix environment, so some plumbing can be used. I _think_ you should be able to get at this using the XSLT system-property() function, but I haven't been able to get this to work as I hoped (and didn't get any response to my query here on the subject a couple of weeks ago.) However, using XT, you can call the getProperty method of java.lang.System directly to access properties specified at run time. Something like: <?xml version="1.0"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/XSL/Transform/1.0" xmlns:prop="http://www.jclark.com/xt/java/java.lang.System" result-ns=""> <xsl:template match="/"> <xsl:value-of select="prop:get-property('my.prop')"/> </xsl:template> </xsl:stylesheet> when run from the DOS command line with java -Dmy.prop=xxx com.jclark.xsl.sax.Driver prop.xml prop.xsl generates: xxx so if you can put the values you require into properties in whatever procedure invokes XT, then I think you should be in business. Pete Johnston University of Glasgow XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
XT: Output current users' login and, Kai Großjohann | Thread | Re: XT: Output current users' login, Kai Großjohann |
help, AposToliS Mikronis | Date | Re: Media, charset, title attribute, Paul W. Abrahams |
Month |