osfa Posted June 8, 2021 Share Posted June 8, 2021 Tenemos un proyecto que funcionaba correctamente la actualización de precio y stock con la API, pero hace mas de un mes dejo de funcionar y no sabemos que puede pasar, ya hemos tratado de revisar todo lo que esta en nuestras manos , pero no lo conseguimos, cualquier ayuda será bienvenida,el error que nos muestra: HTTP XML response is not parsable: array ( 0 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 41, 'column' => 6, 'message' => 'Specification mandate value for attribute async ', 'file' => '', 'line' => 18, )), 1 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 65, 'column' => 6, 'message' => 'attributes construct error ', 'file' => '', 'line' => 18, )), 2 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 73, 'column' => 6, 'message' => 'Couldn\'t find end of Start Tag script line 17 ', 'file' => '', 'line' => 18, )), 3 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 76, 'column' => 14, 'message' => 'Opening and ending tag mismatch: link line 12 and script ', 'file' => '', 'line' => 19, )), 4 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 76, 'column' => 8, 'message' => 'Opening and ending tag mismatch: link line 6 and head ', 'file' => '', 'line' => 196, )), 5 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 68, 'column' => 66, 'message' => 'xmlParseEntityRef: no name ', 'file' => '', 'line' => 374, )), 6 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 68, 'column' => 24, 'message' => 'StartTag: invalid element name ', 'file' => '', 'line' => 392, )), 7 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 68, 'column' => 55, 'message' => 'xmlParseEntityRef: no name ', 'file' => '', 'line' => 397, )), 8 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 76, 'column' => 10, 'message' => 'Opening and ending tag mismatch: li line 353 and script ', 'file' => '', 'line' => 401, )), 9 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 76, 'column' => 23, 'message' => 'Opening and ending tag mismatch: img line 405 and div ', 'file' => '', 'line' => 406, )), 10 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 76, 'column' => 11, 'message' => 'Opening and ending tag mismatch: script line 316 and div ', 'file' => '', 'line' => 424, )), 11 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 68, 'column' => 40, 'message' => 'xmlParseEntityRef: no name ', 'file' => '', 'line' => 493, )), 12 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 68, 'column' => 41, 'message' => 'xmlParseEntityRef: no name ', 'file' => '', 'line' => 493, )), 13 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 68, 'column' => 54, 'message' => 'xmlParseEntityRef: no name ', 'file' => '', 'line' => 568, )), 14 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 68, 'column' => 55, 'message' => 'xmlParseEntityRef: no name ', 'file' => '', 'line' => 568, )), 15 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 76, 'column' => 8, 'message' => 'Opening and ending tag mismatch: div line 219 and body ', 'file' => '', 'line' => 587, )), 16 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 76, 'column' => 8, 'message' => 'Opening and ending tag mismatch: div line 198 and html ', 'file' => '', 'line' => 588, )), 17 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 77, 'column' => 8, 'message' => 'Premature end of data in tag body line 197 ', 'file' => '', 'line' => 588, )), 18 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 77, 'column' => 8, 'message' => 'Premature end of data in tag meta line 4 ', 'file' => '', 'line' => 588, )), 19 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 77, 'column' => 8, 'message' => 'Premature end of data in tag head line 3 ', 'file' => '', 'line' => 588, )), 20 => LibXMLError::__set_state(array( 'level' => 3, 'code' => 77, 'column' => 8, 'message' => 'Premature end of data in tag html line 2 ', 'file' => '', 'line' => 588, )), ) Link to comment Share on other sites More sharing options...
w3bsolutions Posted June 9, 2021 Share Posted June 9, 2021 (edited) Sólo con el error es prácticamente imposible decirte dónde está el problema, necesitamos que pongas también la petición completa (qué URL de la API y el cuerpo de la petición, sobre todo). Hay que ver qué datos estás enviando que pueden producir ese error. Edited June 9, 2021 by w3bsolutions (see edit history) Link to comment Share on other sites More sharing options...
osfa Posted June 9, 2021 Author Share Posted June 9, 2021 Hola, gracias por tu ayuda. La solicitud vía Api que envió es: <?php require_once('PSWebServiceLibraryv7.php'); $webService = new PrestaShopWebservice(PS_SHOP_PATH, PS_WS_AUTH_KEY, DEBUG); try{ $opt['resource'] = 'products'; $opt['display'] = 'full'; $xml = $webService->get($opt); $resources = $xml -> children() -> children(); catch (PrestaShopWebserviceException $ex) { echo $ex->getMessage(): } ?> Al ejecutar lo anterior me muestra el error que envié, el problema es que el mismo código venia funcionando correctamente hasta hace un mes. Versión Prestashop: 1.7.4.4 Si os hace falta algún otro dato adicional, indicármelo. Cualquier ayuda es bien recibida. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now