title: Convert simpleXML object to string - php
body: <p>I want to convert my XML object to string format. 
  Currently I have an XML object. I want to concatenate it to a string. To be able to do that, I want to convert the XML object to a string.</p>
  
  <pre><code>&lt;?xml version='1.0' encoding='UTF-8'?&gt;
  &lt;soapenv:Envelope xmlns:soapenv='http://schemas.xmlsoap.org/soap/envelope/'&gt;
   &lt;soapenv:Header /&gt;
   &lt;soapenv:Body&gt;
    &lt;ser:processTrans&gt;
       &lt;xmlValue&gt;
           &lt;![CDATA[
              &lt;ebpacket&gt; 
                  &lt;head&gt; 
                      &lt;packettype&gt; UserAuthorization&lt;/packettype&gt;
                      &lt;staffcode&gt; ePay_UserName  &lt;/staffcode&gt; 
                      &lt;pwd&gt;  ePay_Password &lt;/pwd&gt; 
                      &lt;env&gt;  ePay_Evnironment  &lt;/env&gt; 
                  &lt;/head&gt; 
                  &lt;body&gt;
                      &lt;email&gt; _username  &lt;/email&gt;
                      &lt;loginpwd&gt;  _password  &lt;/loginpwd&gt;
                      &lt;deviceid&gt;  DeviceId  &lt;/deviceid&gt;
                      &lt;tokenid&gt; TokenId  &lt;/tokenid&gt;
                      &lt;cip&gt;  CustomerIpAddress  &lt;/cip&gt;
                  &lt;/body&gt;
              &lt;/ebpacket&gt;
          ]]&gt;
      &lt;/xmlValue&gt;
    &lt;/ser:processTrans&gt;
  </code></pre>
  
  <p>
  </p>
  
  <p>This is the simpleXML object. I want to convert it to a string to perform string functions on this.</p>