Here is how my scripts on server works.
I can call it this way with file
http://mysite.com/send.php?xml=file.xmlOr I simply call curl with syntax from above
curl -X POST --data-binary @path/to/my-file.txt
http://mysite.com/send.phpI have tried simplepost but it only accepts files from server, so I need to first upload file from local PC to server in same location as my php scripts resides and then call
http://mysite.com/send.php?xml=./file.xmlHere is my php which I call
*****************************
<?php
error_reporting(E_ALL);
ini_set('display_errors', 1);
include_once('xml.php');
$filename = utyGetString($_GET, 'xml', 'php://input');
$xmlData = file_get_contents($filename);
if (strlen($xmlData) > 0)
{
$xml = new MyXML();
echo $xml->ReadXML($xmlData);
}
else
{
echo MyXML::WriteErrorXML('XML Data Empty');
}
?>
*********************************