Hi, Sam, and thanks for the reply and code...

I tried using your code, but still nothing happens
when I try to calculate the payment.  It may be my
implementation of the js or it still may be a problem
in my ColdFusion code.

Do I just stick your code in with my CalculateMortgage function
"as is", or does it need anything else added... or a different position
in the code?

Here's where it lies now:

Thanks!

Rick



<script type="text/javascript">

    // Define CalculateMortgage in the global scope so that it is always
accessible

        function CalculateMortgage(){

            var Params = {};

            $("input:text").each(function(){
            Params[$(this).attr("name")] = $(this).val();
            });

            $.post("callpage_Validate_Mortgage_Inputs.cfm", Params,
function(data){
         
            $("#Result").empty().append(data);
        
            } );
        }
                
                
        $("input:text").bind("keypress",function(e) {
        var key = e.keyCode || e.charCode;
        if(key == 13) {CalculateMortgage();
                }
        }
)

        
        
        $(document).ready(function(){

                $("#Principal").blur(function(){ 
                $.post("callpage_Validate_Mortgage_Inputs.cfm",
{principal:$("#Principal").val()},
                function (data) {$("#Result_Principal").empty().append(data)
} ) });
        
                $("#Interest").blur(function(){
                $.post("callpage_Validate_Mortgage_Inputs.cfm",
{interest:$("#Interest").val()},
                function (data) {$("#Result_Interest").empty().append(data)
}) });
        
                $("#Years").blur(function(){
        
$.post("callpage_Validate_Mortgage_Inputs.cfm",{years:$("#Years").val()},
                function (data) {$("#Result_Years").empty().append(data) })
});
        
        });

</script>




_______________________________________________
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/

Reply via email to