大佬教程收集整理的这篇文章主要介绍了使用SOAP API的android magento客户登录(身份验证),大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
env.dotNet = false; env.xsd = SoapserializationEnvelope.XSD; env.enc = SoapserializationEnvelope.ENc; SoapObject request = new SoapObject(NAMESPACE,"login"); request.addProperty("username","xyz"); request.addProperty("apiKey","xyz"); env.setOutputSoapObject(request); httpTransportSE androidhttpTransport = new httpTransportSE(URL); androidhttpTransport.debug = true; androidhttpTransport.call("",env); Object result = env.getResponse(); Log.d("sessionId",result.toString()); // making call to get list of customers String sessionId = result.toString(); request = new SoapObject(NAMESPACE,"customerCustomerInfo"); request.addProperty("sessionId",sessionId); request.addProperty("customerId","2032"); request.addProperty("email","abc@def.com"); request.addProperty("password","password"); env.setOutputSoapObject(request); androidhttpTransport.call(SOAP_ACTION,env); androidhttpTransport.debug = true; result = env.getResponse(); Log.d("Customer List",result.toString());
}
但它没有帮助我,所以有任何人可以解决我的问题.
谢谢….
require_once( ‘../ magentosite /应用/ Mage.PHP’); // Magento之路
的umask(0);
法师::应用程式();
$id = 1;
尝试{$result = Mage :: getModel(‘customer / customer’) – > setWebsitEID($id) – > authenticate($email,$password);} catch(Exception $E){$result = false;}>使用JSON将用户名和密码从android发送到该PHP页面,并获得“结果”.>如果结果为“true”,则DB中存在用户名和密码.
以上是大佬教程为你收集整理的使用SOAP API的android magento客户登录(身份验证)全部内容,希望文章能够帮你解决使用SOAP API的android magento客户登录(身份验证)所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。