title: WSDL problem with PHP objects, strange <SOAP-ENC:Struct> elements
body: <p>I'm trying to deal with PHP code which is serving some data through WSDL.
  There are two methods in the WSDL file, one of the is working, the other which is totally identical is not.</p>
  
  <p>GetAllProducts returns:</p>
  
  <pre><code>&lt;ns1:GetAllProductsResponse&gt;
      &lt;describedProductArray&gt;
          &lt;DescribedProduct&gt;
              &lt;id&gt; ... &lt;/id&gt;
              &lt;foo&gt; ... &lt;/foo&gt;
          &lt;/DescribedProduct&gt;
          &lt;Describedproduct&gt;
              ...
          &lt;/DescribedProduct&gt;
          ...
  &lt;/describedProductArray&gt;
  etc
  </code></pre>
  
  <p>But GetAllDischargedProducts returns</p>
  
  <pre><code>&lt;ns1:GetAllDischargedProductsResponse&gt;
       &lt;dischargedProductArray&gt;
          &lt;DischargedProduct&gt;
             &lt;SOAP-ENC:Struct&gt;
                &lt;DischargeDate&gt; ... &lt;/DischargeDate&gt;
                &lt;id&gt; ... &lt;/id&gt;
             &lt;/SOAP-ENC:Struct&gt;
             &lt;SOAP-ENC:Struct&gt;
                &lt;DischargeDate&gt; ... &lt;/DischargeDate&gt;
                &lt;id&gt; .. &lt;/id&gt;
             &lt;/SOAP-ENC:Struct&gt;
             ...
          &lt;/DischargedProduct&gt;
      &lt;dischargedProductArray&gt;
  </code></pre>
  
  <p>I have to get rid of these  elements and put each set of data into a separate  element. The PHP part looks ok. I suppose the problem is somewhere in the WSLD file.</p>
  
  <p>The part that describes the data is this:</p>
  
  <pre><code>&lt;complexType name="DescribedProduct"&gt;
      &lt;complexContent&gt;
          &lt;extension base="self:Product"&gt;
              &lt;sequence&gt;
                  &lt;element name="Name" type="self:Name" /&gt;
                  &lt;element name="Barcode" type="self:Barcode" /&gt;
                  &lt;element name="Exportation" type="boolean" /&gt;
                  &lt;element name="Company" type="self:Company" /&gt;
                  &lt;element name="Prescription" type="self:Prescription" /&gt;
                  &lt;element name="CommercialForm" type="self:CommercialForm" /&gt;
                  &lt;element name="IngredientArray" type="self:IngredientArray" /&gt;
                  &lt;element name="DayToExcretion" type="self:DayToExcretion" /&gt;
              &lt;/sequence&gt;
          &lt;/extension&gt;
      &lt;/complexContent&gt;
  &lt;/complexType&gt;
  
  &lt;complexType name="DescribedProductArray"&gt;
      &lt;sequence&gt;
          &lt;element name="DescribedProduct" type="self:DescribedProduct" minOccurs="0" maxOccurs="unbounded" /&gt;
      &lt;/sequence&gt;
  &lt;/complexType&gt;
  
  &lt;simpleType name="DischargeDate"&gt;
      &lt;restriction base="date" /&gt;
  &lt;/simpleType&gt;           
  
  &lt;complexType name="DischargedProduct"&gt;
      &lt;complexContent&gt;
          &lt;extension base="self:Product"&gt;
              &lt;sequence&gt;
                  &lt;element name="DischargeDate" type="self:DischargeDate" /&gt;
              &lt;/sequence&gt;
          &lt;/extension&gt;
      &lt;/complexContent&gt;
  &lt;/complexType&gt;
  
  &lt;complexType name="DischargedProductArray"&gt;
      &lt;sequence&gt;
          &lt;element name="DischargedProduct" type="self:DischargedProduct" minOccurs="0" maxOccurs="unbounded" /&gt;
      &lt;/sequence&gt;
  &lt;/complexType&gt;
  </code></pre>