$filehandler=fopen("E:\\ApacheRoot\\tmp\\".$filename, "rb");
    $IntomysqlPicture=fread($filehandler, $FileSize);
$handler=mysql_connect("localhost","root","")
     or die(mysql_error());
@mysql_select_db("task")
      or die(mysql_error());
    $strInsert="INSERT INTO `images` (theimage) VALUES ($IntomysqlPicture)";
     mysql_query($strInsert,$handler)
     or die(mysql_error());
     mysql_close($handler);