You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

45 lines
1.4 KiB

  1. <%@ language=vbscript codepage="65001" %>
  2. <!--#include file="conn.asp"-->
  3. <!--#include file="function.asp"-->
  4. <%
  5. Response.Charset = "UTF-8"
  6. c_openid = request.cookies("m_openid")
  7. 'if c_openid="" then c_openid="oCVcbv7KuCup-yFON07plMg4IQAU"
  8. c_customer_name = request("name")
  9. c_customer_mobile = request("mobile")
  10. c_customer_idno = request("idno")
  11. csql = "APP_MEMBER_LINKER_EDIT '" & c_openid & "',0,'" & c_customer_name & "','" & c_customer_mobile & "',0,'" & c_customer_idno & "'"
  12. ' response.write csql
  13. set rs=conn.execute(csql)
  14. if not rs.eof then
  15. nnum1 = rs("errcode")
  16. c_rtn = "{""code"":""" & nnum1 & ""","
  17. c_rtn = c_rtn & """info"":""" & rs("errinfo") & """"
  18. nnum2 = rs("linker_count")
  19. if nnum2 - 0 > 0 then
  20. c_rtn = c_rtn & ",""customer"":["
  21. c_rtn1 = ""
  22. do until rs.eof
  23. c_rtn1 = c_rtn1 & "{"
  24. c_rtn1 = c_rtn1 & """customer_id"":""" & rs("id") & ""","
  25. c_rtn1 = c_rtn1 & """customer_name"":""" & rs("customer_name") & ""","
  26. c_rtn1 = c_rtn1 & """customer_mobile"":""" & rs("customer_mobile") & ""","
  27. c_rtn1 = c_rtn1 & """customer_idtype"":""" & rs("customer_id_type") & ""","
  28. c_rtn1 = c_rtn1 & """customer_idno"":""" & rs("customer_id_no") & """},"
  29. rs.movenext
  30. loop
  31. if right(c_rtn1,1)="," then c_rtn1 = left(c_rtn1,len(c_rtn1)-1)
  32. c_rtn = c_rtn & c_rtn1
  33. c_rtn = c_rtn & " ]" & vbcrlf
  34. end if
  35. c_rtn = c_rtn & "}" & vbcrlf
  36. end if
  37. rs.close
  38. response.write c_rtn
  39. %>