wantabe2
asked on
Place a Link in PHP Code
Is there a way for me to place a link named "Edit" on the line where is have ***I NEED TO PLACE A LINK HERE TO GO TO FILE edit.php*** in the attached code?
I just need the word "Edit" to be shown in the table so I can click on it to take me to the edit.php file.
I just need the word "Edit" to be shown in the table so I can click on it to take me to the edit.php file.
<?php
$con = mysql_connect("localhost","uname","password");
if (!$con)
{
die('Could not connect: ' . mysql_error());
}
mysql_select_db("mydatabase", $con);
$result = mysql_query("SELECT * FROM mytagble");
echo "<table border='7'>
<tr>
<th>First Name</th>
<th>Last Name</th>
<th>Status</th>
<th>Edit</th>
<th></th>
</tr>";
while($row = mysql_fetch_array($result))
{
echo "<tr>";
echo "<td>" . $row['fname'] . "</td>";
echo "<td>" . $row['lname'] . "</td>";
echo "<td>" . $row['status'] . "</td>";
***I NEED TO PLACE A LINK HERE TO GO TO FILE edit.php***
echo "</tr>";
}
echo "</table>";
?>
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.