Velocity 1.5 has event handlers that can be used to automatically escape references in a variety of formats (HTML, Javascript, etc). You can specify which reference it affects via a regular expression.
http://velocity.apache.org/engine/releases/velocity-1.5/developer-guide.html#configuring_event_handlers see org.apache.velocity.app.event.implement.EscapeJavascriptReference WILL On 6/27/07, Claude Brisson <[EMAIL PROTECTED]> wrote:
(Please use the user list for such questions) Is this value enclosed in quotes ? esc.javascript mainly escape quotes and line-feeds, so "$!esc.javascript(...)" should generate a single one-line string. Claude Le mercredi 27 juin 2007 à 00:36 -0700, Arora a écrit : > Hi All, > I am currently facing issue in my HTML+javascript application which use > velocity engine because of tag appears in the saved content. I am
fetching
> the value from the database and doing $!esc.javascript to it and then > setting the value to the html input type='text' . this flow I can not > change. > please help me to resolve this as we are not escaping the '/' within the > engine. I am using velocity 1.5 > > regards > Ajay --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
-- Forio Business Simulations Will Glass-Husain [EMAIL PROTECTED] www.forio.com
