function click_78f15f4dc406ba20ad9719eae9d27a48( aform_reference ) { var aform = aform_reference; aform['amount'].value = Math.round( aform['amount'].value*Math.pow( 10,2 ) )/Math.pow( 10,2 ); aform['custom_amount'].value = aform['custom_amount'].value.replace( /^\s+|\s+$/g,"" ); if( !aform['custom_amount'].value || 0 === aform['custom_amount'].value.length || /^\s*$/.test( aform['custom_amount'].value ) ) { alert ( 'An amount is required' ); return false; } aform['amount'].value = Math.round( aform['custom_amount'].value*Math.pow( 10,2 ) )/Math.pow( 10,2 ); }