Rajat Rajat - 25 days ago 8
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.