Question: I need help with my php code. This is my code, this is my output, but i dont want it to be horizontal like this

I need help with my php code. This is my code,

$servername = "localhost";

$username = "root";

$password = "";

$dbname = "student";

// Create connection

$conn = new mysqli($servername, $username, $password, $dbname);

// Check connection

if ($conn->connect_error) {

die("Connection failed: " . $conn->connect_error);

}

//create and execute query

$sql = "SELECT * FROM studentdata";

$result = $conn->query($sql);

//check if records were returned

if ($result->num_rows > 0) {

//create a table to display the record

echo '

';

echo '

';

// output data of each row

while($row = $result->fetch_assoc()) {

echo '

';

echo '

';

echo '

';

echo '

';

echo '

';

echo '

';

echo '

';

echo '

';

}

}

else {

echo "0 results"; //if no record found in the database

}

//close connection

$conn->close();

?>

I need help with my php code. This is my code, thisthis is my output, but i dont want it to be horizontal like this

is my output, but i dont want it to be horizontal likei want it to be Vertical like this and i done so many thing and still failed. pls help me. tq so much

localhost/finalproject/view.php Home FAQ About STUDENT INFORMATION DATABASE WEB SYSTEM Name IdentificationCard Email Gender Religion Nation Phone Number Search Delete MUHAMMAD AZIM BIN ABDUL HAD 970709085185 azimhadi63@gmail.com male ISLAM MELAYU 0129495567 suzana binti zaini 730208086232 suzana123@gmail.com Female ISLAM MELAYU 01459238123 localhost/finalproject/saveRegistrationNew.php Home FAQ About View Student Data STUDENT INFORMATION DATABASE WEB SYSTEM STUDENT INFORMATION DATABASE WEB SYSTEM Date: 03-03-2021 Student Information Name Identification Card Email Gender Religion Nation Phone Mobile Address - Sofiyyah - 970709085189 sofi@gmail.com : Female ISLAM : MELAYU : 0153325367 055256673 11, PERSIARAN PUNCAK JELAPANG 9, PUNCAK JELAPANG MAJU 30020 IPOH PERAK
Name IdentificationCard Email Gender Religion Nation Phone Number Search Delete
'.$row["Name"].''.$row["IdentificationCard"].''.$row["StudentEmail"].''.$row["StudentGender"].''.$row["StudentReligion"].''.$row["StudentNation"].''.$row["StudentMobile"].'

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!