表单提交

1. ajax post 请求提交

//ajax的post方式提交表单
        //$("#itemAddForm").serialize()将表单序列号为key-value形式的字符串
        $.post("/item/save",$("#itemAddForm").serialize(), function(data){
            if(data.status == 200){
                $.messager.alert('提示','新增商品成功!');
            }
        });
原文地址:https://www.cnblogs.com/redhat0019/p/9475263.html