title: how to use div tag inside <td> in php code
body: <p>I want to know how should we use div tags inside a table in PHP code. This is my code. Please tell me how to use it properly.</p>
  
  <pre><code>&lt;tbody&gt;
      &lt;?php
      $result = mysqli_query($conn,$sql);
      while($row = mysqli_fetch_array($result,MYSQLI_BOTH)) {  
  
          echo "&lt;tr&gt;
  
          &lt;td&gt;{$row['id']}&lt;/td&gt;
          &lt;td&gt;&lt;img  width='90px' height='90px' src='imageView.php?id=".$row["id"]."' /&gt; &lt;/td&gt;
          &lt;td&gt;{$row['item_name']}&lt;/td&gt;
          &lt;td&gt;{$row['description']}&lt;/td&gt;
          &lt;td&gt;{$row['quantity']}&lt;/td&gt;
          &lt;td&gt;echo '&lt;div class="col-md-1 col-sm-3 col-xs-6 c-cart-qty"&gt;
  
              &lt;div class="c-input-group c-spinner"&gt;
                  &lt;input type="text" class="form-control c-item-1" value="1"&gt;
                  &lt;div class="c-input-group-btn-vertical"&gt;
                      &lt;button class="btn btn-default" type="button" data_input="c-item-1"&gt;
                          &lt;i class="fa fa-caret-up"&gt;&lt;/i&gt;
                      &lt;/button&gt;
                      &lt;button class="btn btn-default" type="button" data_input="c-item-1"&gt;
                          &lt;i class="fa fa-caret-down"&gt;&lt;/i&gt;
                      &lt;/button&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
          &lt;/div&gt; 
          &lt;/td&gt;';                                                 
          &lt;td&gt; &lt;button&gt;submit&lt;/button&gt;  &lt;/td&gt;
  
          &lt;/tr&gt;";
  
  
      }?&gt;
  &lt;/tbody&gt;
  </code></pre>
  
  <p>I have tried using inverted comma's and braces but still, it shows error. What needs to be done here?</p>