any user agent (=web browser) just passes strings. to get float, either in the form use <input type=hidden name="shipping:float" value=<dtml-var shipping>> (see: http://www.zope.org/Members/Zen/howto/FormVariableTypes) or initially (after being called from the browser) <dtml-call "REQUEST.set('shipping',_.float(subtotal)*.05)">