> thanks, but as you suspected...I don't have access to > the underlying code. Thats the problems. > > this has to be done in template toolkit alone!
As far as I know, there is no simple way to perform string replacement with back-reference in TT. It is a subject to work on. If you have EVAL_PERL enabled, then just use perl code to do this: [% PERL %] My $t = $stash->get( 't' ); $t =~ s/(cat)(dog)/$1,$2/ig; $stash->set( 't', $t ); [% END %] (not checking syntax) -- Sergey Martynoff _______________________________________________ templates mailing list [email protected] http://lists.template-toolkit.org/mailman/listinfo/templates
