Hvordan kører jeg denne function
Hejsa,Jeg har denne kodestump fra Mailchimp.com i ASP, men jeg er i tvivl om hvorledes jeg kører den??
Håber der er nogle som kan hjælpe!
'Define these variables.
Dim apikey
Dim listid
Dim MCURL
Function listSubscribe (strEmail, strFirstName, strLastName, strPhone)
Dim resp
Dim merge_vars
Dim ParamArr
Set merge_vars = Server.CreateObject("Scripting.Dictionary")
With merge_vars
.Add "OPTINIP", Request.ServerVariables("REMOTE_ADDR")
.Add "double_optin", False
.Add "FNAME", strFirstName
.Add "LNAME", strLastName
.Add "phone", strPhone
End With
'Function Reference: listSubscribe(string apikey, string id, string email_address, array merge_vars, string email_type, boolean double_optin, boolean update_existing, boolean replace_interests, boolean send_welcome)
'NOTE THAT EMPTY VALUES DO NOT WORK WELL WITH THIS VERSION OF XLMRPC.ASP. BEST TO SEND EMPTY STRINGS.
ParamArr = array(apikey,listid,strEmail,merge_vars,"",True,True,True,True)
resp = xmlRPC(MCURL,"listSubscribe",ParamArr)
'Uncomment below for Error Checking
Response.Write(Session("xmltxt")&"<br>")
Response.Write(Session("ServerResponseText")&"<br>")
LGNListSubscribe = resp
End Function