Rajat Rajat - 1 year ago 66
PHP Question

After update button is clicked,than it does not go to php file written inside anchor tag?

Here is the code Snippet :

echo "<td><a href=SalaryUpdateForm.php?id = " . $resultArr["EmployeeId"] . " Update </a></td>";

Answer Source

try below code , this will helpful to you.

 $id = $resultArr["EmployeeId"];
 echo "<td><a href='SalaryUpdateForm.php?id=$id'>Update..</a></td>";


 echo "<td><a href='SalaryUpdateForm.php?id=$resultArr[EmployeeId]'>Update..</a></td>";

When you use "" then you can easily use php variables without concatinate.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download