XMLRPC PROBLEM WITH dateCreated
-
i try to post an article on 2011/03/01
but i have this
faultCode -32700 faultString parse error. not well formed
faultCode -32700 faultString parse error. not well formed
faultCode -32700 faultString parse error. not well formed$titolo =’title’;
$testo =’text’;
$admin = ‘Link’;
$pass = ‘compressione0290’;$data = strtotime(“2011/02/28 14:00:00”);
$request = ‘
<?xml version=”1.0″ encoding=”iso-8859-1″?>
<methodCall>
<methodName>metaWeblog.newPost</methodName>
<params>
<param>
<value>
<string>MyBlog</string>
</value>
</param>
<param>
<value>Link</value>
</param>
<param>
<value>
<string>compressione0290</string>
</value>
</param>
<param>
<struct>
<member>
<name>categories</name>
<value>
<array>
<data>
<value>Adventures</value>
</data>
</array>
</value>
</member>
<member>
<name>description</name>
<value>Yeti</value>
</member>
<member>
<name>title</name>
<value>Expedition To Khumbu</value>
</member>
<member>
<name>dateCreated</name>
<value>
<dateTime.iso8601>’ .$data. ‘</ dateTime.iso8601>
</value>
</member>
</struct>
</param>
<param>
<value>
<boolean>1</boolean>
</value>
</param>
</params>
</methodCall>’;$xmlresponse = get_response(“secret”, $request); // my blogs on wordpress.com
}
function get_response($URL, $context) {
if(!function_exists(‘curl_init’)) {
die (“Curl PHP package not installedn”);
}/*Initializing CURL*/
$curlHandle = curl_init();/*The URL to be downloaded is set*/
curl_setopt($curlHandle, CURLOPT_URL, $URL);
curl_setopt($curlHandle, CURLOPT_HEADER, false);
curl_setopt($curlHandle, CURLOPT_HTTPHEADER, array(“Content-Type: text/xml”));
curl_setopt($curlHandle, CURLOPT_POSTFIELDS, $context);/*Now execute the CURL, download the URL specified*/
$response = curl_exec($curlHandle);
return $response;
curl_close($curlHandle);}
where is the error?
pleaseThe blog I need help with is: (visible only to logged in users)
-
The wordpress.COM blog linked to your username is devoid of content. So I assume from that code above that this thread applies to another blog and that it is a wordpress.ORG install.
You forgot to read the sticky post at the head of this forum. We cannot help you here ar all. We provide support only to those with free blogs from and being free hosted by wordpress.COM.
For clarity read > https://en.forums.wordpress.com/topic/please-read-me-first-before-posting?replies=1
And if this is about a wordpress.ORG insatll for self hosting then the correct support forum fo it is here. http://worddpress.org/support/
- The topic ‘XMLRPC PROBLEM WITH dateCreated’ is closed to new replies.