hey guys so im trying to display data into text boxes that are fetched from database according to checkbox with value id.
php:
<?php
if(isset($_POST['edit_event']) && isset($_POST['check']))
{
require "connection.php";
foreach($_POST['check'] as $del_id)
{
$del_id = (int)$del_id;
$sql = mysql_query("SELECT * FROM event WHERE event_id = '$id' ") or die(mysql_error());
$rw = mysql_fetch_array($sql);
}
}
?>
one of the textbox:
<input type="text" name="ename" value="<?php if(@$sql){echo htmlentities (@$rw['event_name']);}?>"
im using the coding i used for a different project but with a little tweek here and there but it doesnt seem to work. as in the textboxes are empty, the data isnt in there.
thanks in advance!