Jump to content

Edit with Webservice the order status only


NeedZoom

Recommended Posts

Hi

 

how i can edit the status of the order in php with webservice?

$xml = $webService->get(array('url' => $url.'/api/order_histories?schema=blank'));
$xml->order_history->id_order = getOrderId($data[0]);
$xml->order_history->id_order_state = '5';
$opt = array('resource' => 'order_histories');
$opt['postXml'] = $xml->asXML();
$xml = $webService->add($opt);


i have error :

HTTP XML response is not parsable: array ( 0 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 64, 'column' => 6, 'message' => 'XML declaration allowed only at the start of the document ', 'file' => '', 'line' => 597, )), 1 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 77, 'column' => 1, 'message' => 'Premature end of data in tag br line 596 ', 'file' => '', 'line' => 607, )), 2 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 77, 'column' => 1, 'message' => 'Premature end of data in tag br line 595 ', 'file' => '', 'line' => 607, )), 3 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 77, 'column' => 1, 'message' => 'Premature end of data in tag br line 1 ', 'file' => '', 'line' => 607, )), )
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...