title: Strange Array and cannot do replacement
body: <p>I have this Array from an API.  I want to replace the word 'test' with 'yes'</p>
  
  <p>I have tried all kinds of stuff... can you help.</p>
  
  <p>Here is the array.</p>
  
  <p>I tried string replace and a few others.  I think it is not a standard array.  Looks like the values are wrong.  Please help.</p>
  
  <pre><code>Array
  (
      [0] =&gt; ATWS\AutotaskObjects\Entity Object
          (
              [Fields] =&gt;
              [UserDefinedFields] =&gt; ATWS\AutotaskObjects\ArrayOfUserDefinedField Object
                  (
                      [UserDefinedField] =&gt;
                  )
  
              [id] =&gt; 35
              [AccountID] =&gt; 218
              [AlertTypeID] =&gt; 1
              [AlertText] =&gt; test
          )
  
      [1] =&gt; ATWS\AutotaskObjects\Entity Object
          (
              [Fields] =&gt;
              [UserDefinedFields] =&gt; ATWS\AutotaskObjects\ArrayOfUserDefinedField Object
                  (
                      [UserDefinedField] =&gt;
                  )
  
              [id] =&gt; 36
              [AccountID] =&gt; 218
              [AlertTypeID] =&gt; 2
              [AlertText] =&gt; test2
          )
  
      [2] =&gt; ATWS\AutotaskObjects\Entity Object
          (
              [Fields] =&gt;
              [UserDefinedFields] =&gt; ATWS\AutotaskObjects\ArrayOfUserDefinedField Object
                  (
                      [UserDefinedField] =&gt;
                  )
  
              [id] =&gt; 37
              [AccountID] =&gt; 218
              [AlertTypeID] =&gt; 3
              [AlertText] =&gt; test3
          )
  
  )
  </code></pre>
  
  <p>Bonus... Can it be done with this array?
  OK Bonus question
  what if it was</p>
  
  <pre><code>ATWS\AutotaskObjects\QueryResponse Object
  (
      [queryResult] =&gt; ATWS\AutotaskObjects\ATWSResponse Object
          (
              [EntityResults] =&gt; ATWS\AutotaskObjects\ArrayOfEntity Object
                  (
                      [Entity] =&gt; Array
                          (
                              [0] =&gt; ATWS\AutotaskObjects\Entity Object
                               (                          
                                      [id] =&gt; 35
                                      [AccountID] =&gt; 218
                                      [AlertTypeID] =&gt; 1
                                      [AlertText] =&gt; test
                                  )
  </code></pre>