Update my php code so it can look like the output shown in the image.

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

Update my php code so it can look like the output shown in the image. 

<?php
echo "<!DOCTYPE html>\n";
echo "<html>\n";
echo "<head>\n";
echo "<title>Add Product</title>\n";
echo "</head>\n";
echo "<body>\n";
 
if (!isset($_COOKIE['login'])) {
    die("Not logged in. Please <a href='login.html'> login</a> first.");
}
 
$loginValue = $_COOKIE['login'];
 
echo "<form method='post' action='insert_product.php'>";
echo "<label for='product_name'>Product Name:</label>";
echo "<input type='text' name='product_name' id='product_name' required><br><br>";
echo "<form method='post' action='insert_product.php'>";
echo "<label for ='description'>Description:</label>";
echo "<input type ='text' id='description' id='description' required><br><br>";
echo "<input type='radio' name ='product' value='electronics'>Electronics";
    echo "<input type='radio' name ='product' value='furniture'>Furniture";
    echo "<input type='radio' name ='product' value='kitchen'>Kitchen";
 
    
 
echo "<form method='post' action='insert_product.php'>";
    echo "<label for='sell_price'>Sell Price:</label>";
    echo "<input type='text' name='sell_price' id='sell_price' required><br><br>";
 
    echo "<form method='post' action='insert_product.php'>";
    echo "<label for='quantity'>Quantity:</label>";
    echo "<input type='text' name='quantity' id='quantity' required><br><br>";
    echo"<label for='vendor'>Select a vendor:</label>";
    echo "<select name='vendor' id='vendor' required>";
    echo "<option value='XYZ3'>XYZ3</option>";
    echo "<option value='York'>York</option>";
    echo "<option value='TTT'>TTT</option>";
    echo "<option value='QQQ'>QQQ</option>";
    echo "<option value='VVV'>VVV</option>";
    echo "</select><br><br>";
    echo "<input type='submit' value='Submit'>";
    echo "</form>";
 
 
echo "</body>\n";
echo "</html>\n";
?>
**Add Product Form**

This form allows users to input details for adding a new product to an inventory system. The fields and controls included in the form are as follows:

- **Product Name:** A text input field where the user can type the name of the product.
  
- **Description:** A text input field for a brief description of the product.

- **Category Options:** Radio buttons to select the product category. The available options are:
  - Electronics
  - Furniture
  - Kitchen

- **Cost:** A text input field to enter the cost price of the product.
  
- **Sell Price:** A text input field for the selling price of the product.
  
- **Quantity:** A text input field for the quantity of the product in stock.
  
- **Select a Vendor:** A dropdown menu to select a vendor. In the image, "XYZ3" is displayed as a currently selected option.

- **Submit Button:** A button to submit the form once all fields are completed. 

This form is typically used in backend systems to manage inventory, update product listings, or prepare for the launch of new items in an ecommerce platform. It ensures all necessary information is collected in a structured manner.
Transcribed Image Text:**Add Product Form** This form allows users to input details for adding a new product to an inventory system. The fields and controls included in the form are as follows: - **Product Name:** A text input field where the user can type the name of the product. - **Description:** A text input field for a brief description of the product. - **Category Options:** Radio buttons to select the product category. The available options are: - Electronics - Furniture - Kitchen - **Cost:** A text input field to enter the cost price of the product. - **Sell Price:** A text input field for the selling price of the product. - **Quantity:** A text input field for the quantity of the product in stock. - **Select a Vendor:** A dropdown menu to select a vendor. In the image, "XYZ3" is displayed as a currently selected option. - **Submit Button:** A button to submit the form once all fields are completed. This form is typically used in backend systems to manage inventory, update product listings, or prepare for the launch of new items in an ecommerce platform. It ensures all necessary information is collected in a structured manner.
Expert Solution
steps

Step by step

Solved in 5 steps with 3 images

Blurred answer
Knowledge Booster
JQuery and Javascript
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education