<?php $variable="1.234,33"; echo quitar($variable); function quitar($variable){ $sig[]='.'; $sig[]=','; return str_replace($sig,'',$variable);} ?>