DIGIT-ARC read-only archive · snapshot: July 23, 2026

Php query

2 posts · originally from https://geek.digit.in/community/threads/php-query.144502/

S
sudiphans Original post #1
Aug 1, 2011 at 1:45 PM
hai friends,

i have written a code in php to output a data in my webpage by taking the data from mysql database. The data I want to be formatted as tabled output .

I have written a html page which takes the employee id and furnish the details of that employee.

please help me how could i show the single row output in tabled form using php.
krishnandu.sarkar
Aug 1, 2011 at 3:35 PM
PHP:
<html>
<head>
<title></title>
</head>

<body>
<table>
<tr>
<td>Employee ID</td>
<td>Employee Name</td>
</tr>
<tr>
<?php
echo "<td>" . $row['empid'] . "</td>";
echo "<td>" . $row['empname'] . "</td>";
?>
</tr>
</table>
</body>
</html>