Advertisement
Guest User

Untitled

a guest
Jun 25th, 2019
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.81 KB | None | 0 0
  1. <?php
  2. if(!empty($_POST['submit'])){
  3. if (isset($_POST['reportType'])){
  4. $reportType = mysqli_real_escape_string($connection, $_POST['reportType']);
  5. //Also tried $reportType = $_POST['reportType']
  6. }
  7.  
  8. }
  9. ?>`
  10.  
  11. <form method="post" action="" class="reportForm">
  12.  
  13. <select name="reportType" class="form-control" id=reportType>
  14. <option value="Users">Users</option>
  15. <option value="Medicine">Medicines</option>
  16. <option value="Pharmacies">Pharmacies</option>
  17. <option value="Reviews">Reviews</option>
  18. </select>
  19.  
  20. <div class="form-group col-md-2">
  21. <input type="submit" id="reports" value="Generate Report">
  22. </div>
  23.  
  24. <?php
  25.  
  26. if($reportType == "Users"){
  27.  
  28. //This is where I'm getting the error but nothing's posting anyway
  29. }
  30. ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement