i generated this table from fiddler,i sniffed what submit button did so i can make my curl script...this is my script that doesnt work...
PHP Code:
$curl_connection =curl_init('here is the site where i want this script to process');
curl_setopt($curl_connection, CURLOPT_CONNECTTIMEOUT, 30);
curl_setopt($curl_connection, CURLOPT_USERAGENT,
"Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)");
curl_setopt($curl_connection, CURLOPT_RETURNTRANSFER, true);
curl_setopt($curl_connection, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($curl_connection, CURLOPT_FOLLOWLOCATION, 1);
$post_data['appointment']='10:00:00';
$post_data['title']='titl';
$post_data['email']='email';
$post_data['field1']='field1';
$post_data['field2']='field2';
$post_data['option']='com_jxtcappbook';
$post_data['view']='book';
$post_data['task']='save';
$post_data['id']='0';
$post_data['cid[]']='0';
$post_data['ordering']='0';
$post_data['parent_id']='1';
$post_data['published']='1';
$post_data['date']='2012-10-29';
$post_data['duration']='01:00:00';
$post_data['start']='10:00:00';
$post_data['end']='11:00:00';
$post_data['pop']='0';
=>i have put put fields like this just for test<=
foreach($post_data as $key =>$value){
$post_items[]=$key.'='.$value;
}
$post_string=implode('&',$post_items);
curl_setopt($curl_connection,CURLOPT_POST,1);
curl_setopt($curl_connection, CURLOPT_POSTFIELDS, $post_string);
$result = curl_exec($curl_connection);
print_r(curl_getinfo($curl_connection));
curl_close($curl_connection);