|
Subject: Re: (dsssl) Dynamic defines From: Jany Quintard <jany.quintard@xxxxxxx> Date: Tue, 27 Feb 2001 17:19:36 +0100 (MET) |
En réponse à Devin Weaver <ktohg@xxxxxxxxxxxxx>:
> On Mon, Feb 26, 2001 at 11:45:07AM -0800, Russell O'Connor wrote:
> > (define (%show-comments%)
> > (string=? "DRAFT" (attribute-string (tree-root (current-node))
> "STATUS"))
> > )
>
> The following did this for me Thank to everyone. I had to redefine the
> element for comment and remark to use (%show-comments%) instead of
> %show-comments% but that's was fine.
>
> To be a bit clearer I rewrote it to look like this:
> (define (%show-comments%)
> (equal? "draft"
> (attribute-string "status" (tree-root (current-node)))))
>
> Question is "DRAFT" and "STATUS" case sensitive?
I believe it depends on the SGML declaration. See the (normalize string)
function which is in the modular stylesheets :
(define (normalize str)
;; REFENTRY normalize
;; PURP Normalize the str according to the SGML declaration in effect
;; DESC
;; Performs SGML general name normalization on the string;
;; used to compare attribute names and generic identifiers correctly
;; according to the SGML declaration in effect; this is necessary
;; since XML is case-sensitive but the reference concrete syntax and
;; many SGML DTDs are not.
;; /DESC
;; AUTHOR Chris Maden
;; /REFENTRY
(if (string? str)
(general-name-normalize str
(current-node))
str))
Jany.
DSSSList info and archive: http://www.mulberrytech.com/dsssl/dssslist
| Current Thread |
|---|
|
| <- Previous | Index | Next -> |
|---|---|---|
| Re: (dsssl) Dynamic defines, Devin Weaver | Thread | Re: (dsssl) Dynamic defines, Jany Quintard |
| Re: (dsssl) Dynamic defines, Devin Weaver | Date | Re: (dsssl) Dynamic defines, Christopher R. Maden |
| Month |