title: my app is sending an XML file to a server: need some guidance on writing a PHP script to parse the XML file
body: <p>So my iPhone app sends a shopping cart in a XML file to a URL through POST. Here is the line of code that does that</p>
  
  <pre><code>NSString *pathToSerializedCart = [rootPath stringByAppendingPathComponent:@"serializedCart.plist"];
  NSString *shoppingCartString;
  NSData *serializedData;
  if (![fileManager fileExistsAtPath:pathToSerializedCart])
     {
      NSLog(@"ERROR:\nCouldnt find serialized cart in documents folder.");
      return;
     }
  
  
      serializedData = [NSData dataWithContentsOfFile:pathToSerializedCart];
      shoppingCartString = [[NSString alloc] initWithData:serializedData
                                                          encoding:NSUTF8StringEncoding];
      NSLog(@"%@", shoppingCartString);
      [shoppingCartString release];
  
  
      //==========================================================================
  
  
  NSData *returnData = [NSURLConnection sendSynchronousRequest:request 
                                             returningResponse:nil error:nil];
  NSString *returnString = [[NSString alloc] 
                            initWithData:returnData encoding:NSUTF8StringEncoding];
  NSLog(@"%@",returnString);
  [returnString release];
  </code></pre>
  
  <p>Now what Id like to do is put a script on the server in the file <code>welcome.php</code> so that the contents of this XML file are echoed to the browser.</p>
  
  <p>I've looked at many examples but they all talk about the situation where the XML file is present in the same directory as the PHP file on the server. I haven't been able to find examples of PHP code that actually is evoked from an app.</p>
  
  <p>Could someone please point me to the right direction.</p>
  
  <p>Thanks</p>