When I search, I get a result but it returns a blank form. I am able to complete a search with no errors but when complete the search the HTML is empty. I cannot figure out what is wrong here. MySQL connect has been changed for obvious reasons Here is my code:
<?php
    define('DB_NAME', 'name');
    define('DB_USER', 'user');
    define('DB_PASS', 'password');
    define('DB_HOST', 'localhost');
    $link = mysql_connect(DB_HOST, DB_USER, DB_PASS);
    if (!$link) {
        dir('There was a problem when trying to connect to the host. Error: ' . mysql_error());    
    }
    $db_selected = mysql_select_db(DB_NAME, $link);
    if (!$link) {
        dir('There was a problem when trying to connect to the database. Error: ' . mysql_error());    
    }
    $output = ""; 
    if (isset($_POST['search'])) {
        $searchq = $_POST['search'];
        $query = mysql_query("SELECT * FROM fac WHERE firstname LIKE '%$searchq%' OR lastname LIKE '%$searchq%'") or die("Could not complete search");
        $count = mysql_num_rows($query); 
        if ($count == 0) {
            $output = 'There where no search results';
        }else {             
            while ($row = mysql_fetch_array($query)) {
                $fname = $_POST['firstname'];
                $mname = $_POST['middlename'];
                $lname = $_POST['lastname'];
                $address = $_POST['address'];
                $car_type = $_POST['car_type'];
                $plate_number = $_POST['plate_number'];
                $intel = $_POST['intel'];
                $output .='<div> ID:'.$id.' <br /> First Name: </> '.$fname.' <br />  Middle Name: </>'.$mname.' <br />  Last Name: </> '.$lname.' <br />  Address: </> '.$address.' <br />  Car Type: </>'.$car_type.'<br />  Plate Number: </> '.$plate_number.' <br />  Intel: </> '.$intel.' <br />  </h3> </div>  <br />';
            }
        }       
    } 
?>
<html> 
    <head>
        <title>Search</title>
    </head>
    <body>
        <form action="search-entry-fac.php" method="post">
            <input type="text" name="search" placeholder="Search For Entry">
            <input type="submit" name="search_submit" value=">>"
        </form>
        <br />
        <?php print("$output"); ?>
    </body>
</html>
 
     
     
    