[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: XT: Output current users' login and full name?

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
get user full name
[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

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.