How do you put a button with a list across from every box on the left with a cycle?



  • In this line, we extract a list of products from the OBD system, and every product is placed in a separate box on the left.

    <?php foreach($title as $products){echo "<tr><td>$products</td></tr>";}?>
    

    In this line, my performance should also draw a list of products from the cycle and be placed in a box across the street, but I'm already on the list, please tell me how to fix it.

    <?php foreach($title as $products){echo "<option>$products</option>";}?>
    

    How should it be:

    введите сюда описание изображения

    Full code:

    <table border="1"> 
        <tr>
        <td>Номенклатура 1</td>
        <td>Номенклатура 2</td>
        </tr>
        <tr>
        <?php foreach($title as $products){echo "<option>$products</option>";}?>
        <tr>
        <td>
        <select>
            <?php foreach($showproductsdb as $db){ echo "<option>$db->productsiiko</option>";} ?>
        </select>
        </td>
        </tr>
        </tr>
    </table>
    

  • QA Engineer

    <table border="1"> 
        <tr>
        <td>Номенклатура 1</td>
        <td>Номенклатура 2</td>
        </tr>
        <tr>
          <td>
            <select id="product">
            <?php foreach($title as $products){echo "<option>$products</option>";}?>
            </select>
          </td>
          <td>
          <select>
            <?php foreach($showproductsdb as $db){ echo "<option>$db->productsiiko</option>";} ?>
          </select>
          </td>
        </tr>
    </table>
    
    

Log in to reply
 

Suggested Topics

  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2
  • 2