Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $host = "localhost";
- $user = "root";
- $password = "";
- $db = "images";
- $conn=mysqli_connect($host, $user, $password, $db);
- if(!empty($_GET['q'])){
- $q = $_GET['q'];
- $query = "SELECT * FROM names WHERE names like '%$q%'";
- $result = mysqli_query($conn, $query);
- while($row = mysqli_fetch_assoc($result)){
- $name = $row['names'];
- echo '<a href=..........><div class="searchoutput">'.$name.'</a><br><div class="col-md-8"></div></div>';
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement