Comments (2)
The problem here is the way that values are returned out of a simpleXML element. Reading a parameter such as "$response->xml->customerProfileId" still returns a simpleXML element by default, but the $transaction->customerProfileId is looking for a string.
The resolution to this is simply to cast these particular XML elements as strings. You could do this either when reading them from the XML or when entering them into the transaction object. Personally, I would recommend doing it when you read them out of the XML. It would just be a simple change as shown in the three lines below:
$new_customer_id = (string) $response->xml->customerProfileId;
$paymentProfileId = (string) $response->xml->customerPaymentProfileIdList->numericString;
$customerAddressId = (string) $response->xml->customerShippingAddressIdList->numericString;
from sdk-php.
Closing this one as no additional response.
from sdk-php.
Related Issues (20)
- Response class (file) does not exist. HOT 3
- getTransId() not returning expected result
- Need guide about fixing " Posts Are Returning 404 Errors" HOT 1
- TLS Issues with AWS HOT 2
- How to send extra options in charge Customer Profile? I want to send x_duplicate_window=0 in my function which is charging saved profile.
- Proxy server setting for SDK
- net\authorize\api\contract\v1\CreateCustomerProfileFromTransactionResponse does not exist HOT 3
- authorize SDK and PHP74 compatibility warnings and errors from PHP_CodeSniffer-3.6.1 and PHPCompatibility-9.3.5 HOT 1
- E00007:User authentication failed due to invalid authentication values. HOT 1
- Sdk
- jsonSerialize missing return type messages in PHP 8.1 HOT 3
- CreateTransactionController returns null, conflicting examples HOT 3
- After upgrading from 1.9.9 to ^2.x having "className" not found during the class mapping
- AnetApiSchema.xsd.xml
- Error when scanning package for php 8.1 compatibility
- Incorrect responseType in CreateCustomerProfileFromTransactionController HOT 4
- Deprecated: Return type of net\authorize\api\contract\v1\MerchantAuthenticationType::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /var/www/html/vendor/authorizenet/authorizenet/lib/net/authorize/api/contract/v1/MerchantAuthenticationType.php on line 261 HOT 25
- No 8.1 support in 2023 is actually insane. HOT 39
- Payment decline but receive payment in my authorize wallet HOT 2
- method getSubscriptionId() not defined .
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sdk-php.