Invision Community 4: SEO, prepare for v5 and dormant account notifications By Matt November 11, 2024
LaCollision Posted September 28, 2022 Posted September 28, 2022 Hi team, The Nexus VAT validation for EU business addresses seems to not work any longer. In \Tax::validateVAT at line 382: if ( $xml->read() ) { if ( $xml->name === 'soap:Envelope' and $xml->read() ) { if ( $xml->name === 'soap:Body' and $xml->read() ) { if ( $xml->name === 'checkVatResponse' ) { $xml->read(); do { $responseArray[ $xml->name ] = $xml->readString(); } while ( $xml->next() and $xml->nodeType !== $xml::END_ELEMENT ); } } } } The response from the EU service seems to have changed; the XML looks something like that: <env:Envelope xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"> <env:Header/> <env:Body> <ns2:checkVatResponse xmlns:ns2="urn:ec.europa.eu:taxud:vies:services:checkVat:types"> <ns2:countryCode>XX</ns2:countryCode> <ns2:vatNumber>XXXXXX</ns2:vatNumber> <ns2:requestDate>2022-09-28+02:00</ns2:requestDate> <ns2:valid>true</ns2:valid> <ns2:name>XXXXXX</ns2:name> <ns2:address>XXXXXX</ns2:address> </ns2:checkVatResponse> </env:Body> </env:Envelope> ➡️ The namespace is "env", and a <env:Header> tag seems to have appeared before the Body; so the $xml->read() can't find the Body element any longer. Thank you!
Solution opentype Posted September 28, 2022 Solution Posted September 28, 2022 There was a patch for that this week. LaCollision 1
Jim M Posted September 28, 2022 Posted September 28, 2022 As mentioned by @opentype, we issued a patch for this. You can find it by going to ACP -> Support. LaCollision 1
LaCollision Posted September 28, 2022 Author Posted September 28, 2022 Perfect! Thanks a lot to both of you Jim M 1
Recommended Posts