Hello.

I'm a little puzzled about the mentioned extensions. I believe these should be bound
to another namespace to avoid violation of the W3C-specs (since only elements in the
recommendation are allowed in the ns allocated for xsl-elements. Furthermore, I seem
to recall ns:s beginning with the letter 'x' being reserved for standardized
namespaces. This is not followed by neither XTs purposed extension-prefixes nor
Cocoon's XSP though).
   Another thing was the handling of variables/params in the xsl-elements. This
should be done without brackets; those are only used (and allowed) when expanding a
variable inside of an output elements attribute. Thus:

   <a href="{$storage}"><xsl:value-of select="$storage" /></a>

is correct, but not:

   <xsl:value-of select="{$storage}" />

(Here xt signals "illegal character" and exits.) Further:

   <a href="$storage">...</a>

simply produces just that; no expanding as perhaps expected.



And now, off to something else:
   My mentioning of xsp brings me to a little question. Imagine this primitive
[well-formed, thus transformable] example:

       <?xml version='1.0'?>
       <?xpl $attr = 'a piece' ?>
       <xml>
          <?xpl foreach(@list)  { ?>
                 <piece attr="{$attr}"><?xpl =  $_ ?></piece>
          <?xpl }?>
       </xml>

A simple thing I did rather haphazardly when testing embedding perl i html a while
ago, not having installed apache::asp or similar things, was having a perl-script
"parse" such xml-page by use of regexp and multi-line quotes in a rough fashion, then
running it in an eval.

   What I'm getting to is simply an open question: could this technique in any way be
recommended when putting together dynamic xml-pages? Or would it simply be slow,
unsafe and practically silly? It's been brought to my immediate attention when,
having spent some time leaving the perl-hacking behind and practising xslt in a
java-driven environment, I came upon first xml::xslt and then this Sablotron; and
thus the possibility to merge perl and xslt together in an efficient way. (The works
of Matt Sergeant have also inspired me much, although I haven't had the time to try
them out very much.)
   Perhaps using ePerl, embPerl or mentioned apache::asp would be possible/much more
appropriate for this? (Or just glueing together a preprocessing thing before using
such "dynamic pages"..)
   I'm just throwing this here hoping it won't bother anyone, although perhaps a
little far from Sablotron-development in essence? [Though for me - an inspiring pair.
]

regards
Niklas Lindstr�m



Reply via email to