velocity-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nathan Bubna" <nbu...@gmail.com>
Subject Re: Changing '$' and '#' for other symbols - Two velocity processings on the same file
Date Fri, 21 Sep 2007 20:13:41 GMT
No.  You may be able to change the JavaCC grammar we use and rebuild
Velocity, though i haven't tried that myself.

You've probably already found that \$reference and \#macroOrDirective
escaping is unwieldy, especially for doing two rendering passes where
the contexts are different.  If you don't want to rebuild Velocity,
then you could use more robust escaping by putting a $ and # (e.g.
under the keys 'D' and 'H') in the context for your first pass and
replacing the $ and #  that need to survive the first pass with ${D}
and ${H}.  (or if you use the EscapeTool, this would be ${esc.d} and
${esc.h}).

On 9/21/07, Marcelo de Barros Alcantara <cad_malcantara@uolinc.com> wrote:
> Hi,
>
> We use velocity here in the company (a big web portal), and we need to
> process velocity template in two different moments.
>
> Is there a way of telling the engine to not use '$' or '#', but '%' and
> '&' for example? So that one velocity processing do not mess with the
> other velocity one?
>
> Thanks in advance for any help.
>
> Regards,
>
> Marcelo Alcantara
>
>
> AVISO: A informacao contida neste e-mail, bem como em qualquer de seus anexos, e CONFIDENCIAL
e destinada ao uso exclusivo do(s) destinatario(s) acima referido(s), podendo conter informacoes
sigilosas e/ou legalmente protegidas. Caso voce nao seja o destinatario desta mensagem, informamos
que qualquer divulgacao, distribuicao ou copia deste e-mail e/ou de qualquer de seus anexos
e absolutamente proibida. Solicitamos que o remetente seja comunicado imediatamente, respondendo
esta mensagem, e que o original desta mensagem e de seus anexos, bem como toda e qualquer
copia e/ou impressao realizada a partir destes, sejam permanentemente apagados e/ou destruidos.
Informacoes adicionais sobre nossa empresa podem ser obtidas no site http://sobre.uol.com.br/.
>
> NOTICE: The information contained in this e-mail and any attachments thereto is CONFIDENTIAL
and is intended only for use by the recipient named herein and may contain legally privileged
and/or secret information. If you are not the e-mail?s intended recipient, you are hereby
notified that any dissemination, distribution or copy of this e-mail, and/or any attachments
thereto, is strictly prohibited. Please immediately notify the sender replying to the above
mentioned e-mail address, and permanently delete and/or destroy the original and any copy
of this e-mail and/or its attachments, as well as any printout thereof. Additional information
about our company may be obtained through the site http://www.uol.com.br/ir/.
>

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@velocity.apache.org
For additional commands, e-mail: general-help@velocity.apache.org


Mime
View raw message