note 88538 modified in function.curl-setopt by danbrown

From: Date: Tue, 03 Feb 2009 18:48:37 +0000
Subject: note 88538 modified in function.curl-setopt by danbrown
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-150157@lists.php.net to get a copy of this message
To send a post as a different content-type (ie.. application/json or text/xml) add this setopt call <?php curl_setopt($ch, CURLOPT_HTTPHEADERS,array('Content-Type: application/json')); ?> [EDIT BY danbrown AT php DOT net: Contains a typofix by 'KdoubleU' on 3-FEB-09.] --was-- To send a post as a different content-type (ie.. application/json or text/xml) add this setopt call curl_setopt($ch, CURLOPT_HTTPHEADERS,array('Content-Type: application/json")); http://php.net/manual/en/function.curl-setopt.php

« previous php.notes (#150157) next »