You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@velocity.apache.org by ICM S CP guest 5 <IC...@icn.siemens.de> on 2001/10/02 12:23:45 UTC

RE: Where is the TEMPLATE_ROOT directory? - Found!

Thanks for your help!

I am using jetspeed which is using turbine and velocity
At this combination the TEMPLATE_ROOT directory is

  templates/vm

Andreas


Dear Sanchez,

you must swap #include and #parse

#include is for normal files like text or images 
(you can enter more than one filename)

while

#parse is for .vm files (only one file per #parse command)



-----Original Message-----
From: Gualberto Alejandro Sanchez Caceres [mailto:gsanchez@itweb.com.mx]
Sent: Montag, 1. Oktober 2001 17:31
To: 'velocity-user@jakarta.apache.org'
Subject: RE: Where is the TEMPLATE_ROOT directory?


i think that you use #include but if you want include a file that is not
a .vm file test with #parse may be that's the problem

-----Mensaje original-----
De: Gualberto Alejandro Sanchez Caceres [mailto:gsanchez@itweb.com.mx]
Enviado el: Monday, October 01, 2001 2:53 AM
Para: 'velocity-user@jakarta.apache.org'
Asunto: RE: Where is the TEMPLATE_ROOT directory?


Hi! the TEMPLATE_ROOT is the directory ../templates where normally be
GlobalMacros. HereĀ“s the place where you should put the file that you
want to include in a .vm file!

-----Mensaje original-----
De: ICM S CP guest 5 [mailto:ICM-S-CP.guest-5@icn.siemens.de]
Enviado el: Monday, October 01, 2001 1:36 AM
Para: velocity-user@jakarta.apache.org
Asunto: Where is the TEMPLATE_ROOT directory?


The include file may only be under the TEMPLATE_ROOT directory - but
where is it?
I putted my text file in the template directory but nothing happened.
Do I need to set an environment variable called TEMPLATE_ROOT?

Andreas


-----Original Message-----
From: ICM S CP guest 5 [mailto:ICM-S-CP.guest-5@icn.siemens.de]
Sent: Montag, 1. Oktober 2001 15:23
To: velocity-user@jakarta.apache.org
Subject: RE: How to import external files in .vm files


Ops, you're right - I just found it the velocity users guide!
Thanks


-----Original Message-----
From: Dan Bachelder [mailto:chowda@chowda.net]
Sent: Montag, 1. Oktober 2001 15:15
To: velocity-user@jakarta.apache.org
Subject: Re: How to import external files in .vm files


#include
or
#parse 

the second parses the VTL the first does not.

On Mon, 01 October 2001, ICM S CP guest 5 wrote:

> 
> Hi,
> 
> how can I import an external file into my .vm file?
> Is there something like a #File.Read ("mytext.txt") function?
> 
> Andreas

</dan>