Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8554211
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T14:49:46+00:00 2026-06-11T14:49:46+00:00

im making some application form in PHP. im putting all info returned from the

  • 0

im making some application form in PHP.

im putting all info returned from the database into a table.

Now i want to create a button on each line that changes something in the DB of that line.

but i have no idea to do that :S

Thank you!

echo "<table border='1'>
<tr>
<th>Id</th>
<th>Name</th>
<th>Email</th>
<th>age</th>
<th>position</th>
<th>experience</th>
<th>motivation</th>
<th>date</th>
<th>status</th>
<th>test</th>
</tr>";

while($row = mysql_fetch_array($result))
    {
        echo "<tr>";
    echo "<td>" . $row['id'] . "</td>";
    echo "<td>" . $row['name'] . "</td>";
    echo "<td>" . $row['email'] . "</td>";
    echo "<td>" . $row['age'] . "</td>";
    echo "<td>" . $row['position'] . "</td>";
    echo "<td>" . $row['exp'] . "</td>";
    echo "<td>" . $row['motivation'] . "</td>";
    echo "<td>" . $row['date'] . "</td>";
    echo "<td>" . $row['status'] . "</td>";
    echo "<td>" . '<input type="submit" name="submit" value="accept">' . "</td>";
    echo "</tr>";

}
    echo "</table>";

EDIT: get it working using another script:

echo "<td><a href=\"edit.php?id=".$row['id']."&status=app\">Approve</a></td>";

and edit.php:

<?php
include("dbconnect.php");
$member_id = $_GET['id'];
$status = $_GET['status'];
echo $member_id;
echo $status;
if ($status == 'app')
    $query = "update apps set status = 'approved' where id = $member_id";
mysql_query($query) or die (mysql_error());  
?>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T14:49:47+00:00Added an answer on June 11, 2026 at 2:49 pm

    Create small form with parameters in the cell you want the button to do smth. This is the simpliest approach (approach with refresh).

    One more solution is to use AJAX on button click and forward action to some endpoint. This way it would be dynamic and probably what you are want to implement.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

EDITED: Java httpPost into .asp form I am making an application that will display
I am making another windows form application , but some weird things are happening
I know some PHP and now I want to combine it using ajax/jquery. Just
I have a application that's making calls against some WCF services I have hosted
Im making an application in cocoa and wanted to see if some strings in
I'm currently making an application with Backbone.js and some JQuery libraries. Today I work
I'm making an application to act as a hub of some sorts, where the
I'm thinking of making an application where at some points a graph is displayed
I'm going through some old C#.NET code in an ASP.NET application making sure that
I'm going through some old C#.NET code in an ASP.NET application making sure that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.