 <p>Try this.</p> <pre><code>&lt;?php include("connect.php"); if( isset($_GET['del']) ) { $id = (int)$_GET['del']; $sql = "DELETE termekek WHERE id = $id" ; echo "&lt;a href='admin.php'&gt;Back&lt;/a&gt;"; } ?&gt; </code></pre>