我试图通过XAMPP apache服务器运行这个php文件。但它给我发了一个错误:
可能我需要创建一些HTML表单来初始化字段并包含一些库以使用PHP代码吗?
<?php
$username = {testName};
$password = {1234567};
$secret = {yoursecret};
$token = $username.'--'.md5($password).'--'.md5($username.$password.$secret).'/';
$string = "CreateNewLead";
$post = array();
$post['first_name'] = "First";
$post['last_name'] = "Last";
$post['email'] = "email@";blabla.com$post['lead_status'] = "Hot";
$post['lead_source'] = "Direct Mail";
$post['lead_supplier'] = "Supplier1";
$post['city'] = "London";
$post['zip_code'] = "111111";
$post['country'] = "United Kingdom";
$post['address'] = "Street 100";
$post['phone'] = "123456789";
$post['prefix'] = "234";
www.testingurl.com$post['ip'] = "111.222.111.222";
$post['state'] = "State";
$post['language'] = "en";
$post['secondary_email'] = "bla.bla@";
bla.com$post['affiliate_id'] = "12441232";
$post['referrer_id'] = "TST123";
$post['registration_country'] = "United Kingdom";
$post['other_phone'] = "234567890";
$url = 'http://blabla123.somedesign.net/api/v1/';
$ch = curl_init($url.$token.$string);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, $post);
$data = curl_exec($ch);
curl_close($ch);
$get = json_decode($data);
var_dump($get);
?>
答案 0 :(得分:1)
sqlitejdbc-v056.jar
使用一对单引号。