如何在PHP搜索查询中组织数据?

I'm in the process of making a PHP website, where a user can input data, then search through it later, but I can't seem to organize the data :/ Heres my code:

<form action="uploads.php" method="GET"><input id="search" type="text" placeholder="Type here"><input id="submit" type="submit" value="Search"></form></body></html>

When a user searched for their name, it results as so:

firstname=Mickey lastname=Mouse item1= item2= item3= item4= item5= item6=

Is there any way I can add a CSS or something to get the entries to line break or seperate?

In Your display page while displaying the data you can use the <br> tag so that it will display each and every data in different line.

First Name: <?php echo $loopvariable['fname'].'<br />'; ?>

Last Name: <?php echo $loopvariable['lname'].'<br />'; ?>

Like this you can provide for all the data which you print.

Output:

First Name: Name One

Last Name: Name Two

And you can provide as such information using the break tags in separate lines.

Basically in PHP you can echo html code so you can echo <br> statements as in the previous answer you can also echo css and you can create a block of code that you include

<?php
include('SomeMoreCode.php');
?>

You can also echo formatting commands to create a table. Just place the html statements in'' and join html and mysql/php values with .

echo "<table border='1' cellpadding='10'>";
echo "<tr> <th>date</th> <th>Home Team</th> <th></th><th></th><th>Away Team</th> <th></th>  </tr>";
while($row = mysql_fetch_array( $result )) {
echo "<tr>";
echo '<td>' . $row['date'] . '</td>';
echo '<td>' . $row['hometeam'] . '</td>';
echo '<td>' . $row['fthg'] . '</td>';
echo '<td>' . $row['ftag'] . '</td>';
echo '<td>' . $row['awayteam'] . '</td>';
echo '<td><a href="edit.php?id=' . $row['id'] . '">Edit</a></td>';
echo "</tr>";
}
echo "</table>";

non mysql - php only

<?php

$date='19/6/16';
$hometeam='Man United';
$fthg='3';
$ftag='2';
$awayteam='Man City';

echo "<table border='1' cellpadding='10'>";
echo "<tr> <th>date</th> <th>Home Team</th> <th></th><th></th><th>Away Team</th>   </tr>";
echo "<tr>";
echo '<td>' . $date . '</td>';
echo '<td>' . $hometeam . '</td>';
echo '<td>' . $fthg . '</td>';
echo '<td>' . $ftag . '</td>';
echo '<td>' . $awayteam . '</td>';
echo "</tr>";
echo "</table>";
?>