nz_mitch Posted March 14, 2009 Share Posted March 14, 2009 Sorry - the subject is probably totally useless. If a mod can think of a better way of describing it that'll be more helpful to people in the future, please change it! Thanks to the awesome help I got in this thread here, I've got all the information I need ready to load back into a database using the API. The values I've got from the form (which are all loading correctly) are $email_out, $name and $ref. The code I'm using below, which works when the third part (, "ReferringAgent" => "$ref") isn't included is as follow: $result = $cm->subscriberAddWithCustomFields("$email_out","$name", "ReferringAgent" => "$ref"); if($result['Result']['Code'] == 0) echo 'Success'; else echo 'Error : ' . $result['Result']['Message']; With the third part included I get the following PHP error: Parse error: syntax error, unexpected T_DOUBLE_ARROW in /home/www/domain.com/web/api/index.php on line 141 I'm guessing I'm doing something stupid with quotation marks, but I can't figure it out.. Thanks so much in advance! EDIT: Doh! Apparently all I needed to do was make: "ReferringAgent" => "$ref" "ReferringAgent => $ref" Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.