UPDATE using html form (edit button) php/mysql <p>I'm trying to figure out how to UPDATE a post in my db using html form. I have a page with a form using INSERT that successfully uploads data to my db. I also have another page presenting that data using SELECT. On this page I would like to have an Edit button, sending me to a similar page with the original form but this with the data from the db already inserted into the form, for easy editing and updating. Basically I don't know where to start and I need your help! It's an album database btw.</p> <p><strong>form page</strong></p> <pre><code>&lt;form method="post" action="spara2.php" name="std"&gt; &lt;label&gt;Cover:&lt;/label&gt;&lt;br&gt; &lt;input id="file" type="file" name="file"&gt;&lt;br&gt; &lt;label&gt;Title:&lt;/label&gt;&lt;br&gt; &lt;input type="text" name="std_title" size="58"/&gt;&lt;br&gt; &lt;label&gt;Artist:&lt;/label&gt;&lt;br&gt; &lt;input type="text" name="std_artist" size="58"/&gt;&lt;br&gt; &lt;label for="select"&gt;&lt;br&gt; Year:&lt;/label&gt;&lt;br&gt; &lt;select name="std_year"&gt; &lt;option value="2014"&gt;2014&lt;/option&gt; &lt;option value="2013"&gt;2013&lt;/option&gt; &lt;option value="2012"&gt;2012&lt;/option&gt; &lt;option value="2011"&gt;2011&lt;/option&gt; &lt;option value="2010"&gt;2010&lt;/option&gt; &lt;option value="2009"&gt;2009&lt;/option&gt; &lt;option value="2008"&gt;2008&lt;/option&gt; &lt;option value="2007"&gt;2007&lt;/option&gt; &lt;option value="2006"&gt;2006&lt;/option&gt; &lt;/select&gt;&lt;br&gt; &lt;label&gt;Description:&lt;/label&gt;&lt;br&gt; &lt;textarea name="std_beskriv" cols="45" rows="7"&gt; &lt;/textarea&gt;&lt;br&gt; &lt;label&gt;Tracks:&lt;/label&gt;&lt;br&gt; &lt;textarea name="std_lista" cols="45" rows="7"&gt; &lt;/textarea&gt;&lt;br&gt; &lt;label&gt;Spotify HTTP Link:&lt;/label&gt;&lt;br&gt; &lt;input type="text" name="std_spotify" size="58"/&gt;&lt;br&gt; &lt;br&gt; &lt;label for="reset"&gt;&lt;/label&gt;&lt;input type="reset" value="Reset"/&gt; &lt;label for="save"&gt;&lt;/label&gt;&lt;input type="submit" name="std_save" value="Save"/&gt; &lt;/form&gt; </code></pre> <p> </p> <p>My db is called album and the table musik. I want a similar page but with the data from the db inserted into it. My table has:</p> <ol> <li>id</li> <li>title</li> <li>artist</li> <li>year</li> <li>beskriv</li> <li>tracks</li> <li>spotify</li> <li>date</li> </ol> <p>Since there's a lot of posts in the db how can I select specific entry's so that I can edit one album at a time?</p> <p>Hope you can understand what i'm after.</p> <p>Thanks!</p>