How to load a simplexmlobject file into a variable
<p>I am going crazy here...</p>

<p>I already have a SimpleXMLElement Object so it is not an XML file...
I got it stored in a file object.txt</p>

<p>Now i want to put this object into a variable, but i can't get it to work...?</p>

<p>the SimpleXMLElement Object looks like this:</p>

<p>SimpleXMLElement Object
(
    [PubmedArticle] => Array
        (
            [0] => SimpleXMLElement Object
                (
                    [MedlineCitation] => SimpleXMLElement Object
                        (
                            [@attributes] => Array
                                (
                                    [Owner] => NLM
                                    [Status] => In-Process
                                )</p>

<pre><code>                        [PMID] =&gt; 20538400
                        [DateCreated] =&gt; SimpleXMLElement Object
                            (
                                [Year] =&gt; 2010
                                [Month] =&gt; 07
                                [Day] =&gt; 08
                            )

                        [Article] =&gt; SimpleXMLElement Object
                            (
                                [@attributes] =&gt; Array
                                    (
                                        [PubModel] =&gt; Print-Electronic
                                    )
</code></pre>

<p>.....etc etc....</p>

<p>how do i put this into a variable??</p>

<p>i tried this:
$simplexml = file_get_contents('object.xml');</p>

<p>$simplexml should be an array</p>
