You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@velocity.apache.org by Janek Schwarz <ja...@janek.org> on 2002/06/16 18:06:19 UTC

DVSL: xsl:import like idiom

Hello,

is there a way to modularize my dvsl template in a similar way 
one could do it in xslt with xslt:import?
I tried the following approach:

master.dvsl:
#parse(stylesheets/common.dvsl)
#parse(stylesheets/news.dvsl)
#parse(stylesheets/tour.dvsl)

common.dvsl:
#match("document)
...
#end
...

news.dvsl:
#match("newslist")
...
#end
...

etc.

Unfortunately, it doesn't work. It seems that DVSL uses only 
the templates it finds in common.dvsl.

Is there anything that I miss?

Janek.



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: DVSL: xsl:import like idiom

Posted by Janek Schwarz <ja...@janek.org>.
On Sun, 16 Jun 2002 12:19:53 -0400, Geir Magnusson Jr. wrote:

>No, I'm not surprised.  The registration of the match templates 
happens at a
>different time than the #parse() gets executed.
>
>I suppose an #import() statement would solve the problem?

I'd love to see that feature.

Janek.



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


Re: DVSL: xsl:import like idiom

Posted by "Geir Magnusson Jr." <ge...@adeptra.com>.
On 6/16/02 12:06 PM, "Janek Schwarz" <ja...@janek.org> wrote:

> Hello,
> 
> is there a way to modularize my dvsl template in a similar way
> one could do it in xslt with xslt:import?
> I tried the following approach:
> 
> master.dvsl:
> #parse(stylesheets/common.dvsl)
> #parse(stylesheets/news.dvsl)
> #parse(stylesheets/tour.dvsl)
> 
> common.dvsl:
> #match("document)
> ...
> #end
> ...
> 
> news.dvsl:
> #match("newslist")
> ...
> #end
> ...
> 
> etc.
> 
> Unfortunately, it doesn't work. It seems that DVSL uses only
> the templates it finds in common.dvsl.
> 
> Is there anything that I miss?

No, I'm not surprised.  The registration of the match templates happens at a
different time than the #parse() gets executed.

I suppose an #import() statement would solve the problem?


-- 
Geir Magnusson Jr. 
Research & Development, Adeptra Inc.
geirm@adeptra.com
+1-203-247-1713



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>