Skip to content
Advertisement

Proper way to send (POST) xml with guzzle 6

I want to perform a post with guzzle sending an xml file. I did not find an example.

What I ‘ve done so far is :

JavaScript

No matter what I try I get back error -1 which means that xml is not valid. XML that I send passes online validation though and is valid %100

Please help.

Advertisement

Answer

After some experiments, I have figured it out. Here is my solution in case someone reaches a dead end.

JavaScript
User contributions licensed under: CC BY-SA
8 People found this is helpful
Advertisement