Jump to content

Notice: Undefined index: task in


rabesh

Recommended Posts

Hi,

 

It seems that task is not being passed into the script, check your url contains something like index.php?task=value.

 

it may be better to check task is set before you continue by doing

 

// Check that task has been passed to the script
if (isset($_GET['task'])) {
    if($_GET['task']=='del')
   {
      $id=$_GET['id'];
      $name=$_GET['new_image'];
      mysql_query('delete from tbl_gallery where id="'.$id.'"' );   
      unlink ($name);
   }
}

 

Hope this helps,

 

DK

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.