Basically what i want is a substitute function.
Like 'replace()' but for strings rather than characters.

I would like the servlet to open up a template file
replace keys with strings (which are values taken from
a database... not that that matters) then print the
resulting data to the browsing client.

In this way i can liberate input and output data forms
from the servlet allowing others to change them with
no knowledge of java, nor needing to recompile etc.
Infact the changes would be basically on the fly.

Did that make sense? Anyway.

With perl i would probably do something *like* ...

$value =~ s/<key>/$value/g;

(please note the *like*)

Thanks people

Dean



-- 
SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/
More Info: http://slug.org.au/lists/listinfo/slug

Reply via email to