title: Parse error: syntax error, unexpected 'post_type' (T_STRING) in your code on line 34
body: <p>I get a</p>
  
  <blockquote>
    <p>Parse error:<br>
    syntax error, unexpected 'post_type' (T_STRING) in your code on line 34 </p>
  </blockquote>
  
  <p>How can I solve it?<br>
  This is my code:</p>
  
  <pre><code>if ( $the_service-&gt;have_posts() ) : 
      $output .= '
      &lt;div class="single-sidebar-widget"&gt;
                  &lt;div class="special-links"&gt;';
      $output .= '&lt;ul class="nav nav-tabs single-services-menu" role="tablist"&gt;
                  &lt;li&gt;&lt;a href="http://example.com/all-services/"&gt;All Services&lt;/a&gt;
                      &lt;/li&gt;   
      while ( $the_service-&gt;have_posts() ) : $the_service-&gt;the_post(); $count++;              if ( 0 == $post-&gt;post_parent )      {               $args1 = array(                 'post_type' =&gt; 'services',                  'post_status' =&gt; 'publish',                 'post_parent'    =&gt; get_the_ID(),                   'order'          =&gt; esc_attr($order)                );
              if($varPageID == get_the_ID())
              $varClass = 'class=active';
              else
              $varClass = '';
  
      $output .= '&lt;li role="presentation" '.esc_attr($varClass).'&gt;&lt;a href="'.get_permalink().'"&gt;'.get_the_title().'&lt;/a&gt;
                  &lt;/li&gt;';
  
                  }
      endwhile;
  
      $output .= '
      &lt;/ul&gt;&lt;/div&gt;&lt;/div&gt;';
      else:
          $output .= esc_html( 'Sorry, there is no services under your selected page.', 'plumbing' );
  endif;
  
  wp_reset_postdata();
  echo $output;
  ?&gt;
  </code></pre>
  
  <p>I have found an error in the while loop in VC widget for custom post type services.</p>
  
  <p>How can I solve it?</p>