Webservice调用不插入数据 [英] Webservice call not insert the data

查看:71
本文介绍了Webservice调用不插入数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我正在使用webservice在sql数据库中插入数据。

我使用jquery ajax从html页面调用服务。

服务已调用但未插入数据。

这里我显示的是ajax调用脚本。

请有人帮我解决这个问题。

提前致谢。



Hi,
I am using the webservice to insert the data in sql database.
I am calling the service from html page using jquery ajax.
The service called but not inserted the data.
Here I am showing the ajax call script.
Please anyone help me to resolve this.
Thanks in advance.

var varType;
var varUrl;
var varData;
var varContentType;
var varDataType;
var varProcessData;

function CallService() {
    $.ajax({
        type: varType,
        url: varUrl,
        contentType: varContentType,
        dataType: varDataType,
        async: false,
        success: alert('Yes');
        }
    });
}

推荐答案

.ajax({
类型:varType,
url :varUrl,
contentType:varContentType,
dataType:varDataType,
async: false
success:alert(< span class =code-string>' 是');
}
});
}
.ajax({ type: varType, url: varUrl, contentType: varContentType, dataType: varDataType, async: false, success: alert('Yes'); } }); }


           type: varType,
data:varJsonData,//You Should send data which you want to insert here.(json data as String)
            url: varUrl,
            contentType: varContentType,
            dataType: varDataType,
            async: false,
            success: alert('Yes');
            }
        });pre>


这篇关于Webservice调用不插入数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆