The code below works on my localhost but it doesn't when I make the system live. Any ideas?
Fatal error: Call to undefined method mysqli_stmt::get_result() in /home/.../public_html/test/users.php on line 120
<?php        
        $connection=mysqli_connect("host", "username", "password", "database");
        $sql="SELECT COUNT(*) from database_users";
        $stmt = $connection->prepare($sql);
        $stmt->execute();
        $res = $stmt->get_result();
        $users = $res->fetch_array(MYSQLI_ASSOC);
        if ($users['COUNT(*)'] < 4) {
    ?>
        // html goes here, outside of the php tags
    <?php
        } else {
            echo "Sorry, you have reached the user account limit.";
        };
    ?>
 
     
    