那就用FSO删除啊PHP下用delete($filename)就行了

解决方案 »

  1.   

    unlink();int unlink ( string filename)
    删除 filename。和 Unix C 的 unlink() 函数相似。 如果成功则返回 TRUE,失败则返回 FALSE。 注: 自 PHP 5.0.0 起 unlink() 也可以用于某些 url wrapper。参考 附录 I 中的列表看哪些封装协议支持 unlink()。 
      

  2.   

    那路径那?
    比如删除img下的xx.jpg
    怎么弄啊?
    小弟是asp出身,对php十分久仰!~
      

  3.   

    谢谢各位,俺测试去~回头来给分~
    feel8(准备早起的鸟)兄,问你个问题
    就是早上你给我的代码
    $imageinfo=getimagesize($_FILES['upfile']['tmp_name']);
      if($imageinfo[0] > 120 or $imageinfo[1] > 80{
        echo "图片大小不符合标准";
      }elseif($imageinfo[2] < 1 or $imageinfo[2] > 3){
        echo "简介图片只能是GIF,JPG,PNG格式";
      }
    为什么$imageinfo[0]就是图片的宽度呢?$imageinfo[1]就是图片的高度呢?
    $imageinfo[2]又是格式的判断呢?
    php中这个数组不用定义?
      

  4.   

    getimagesize会返回含有4个元素得数组 这些是函数自己默认的,所以,会有$imageinfo[0]到$imageinfo[3]自己多查查手册getimagesize
    (PHP 3, PHP 4 )getimagesize -- Get the size of an image
    Description
    array getimagesize ( string filename [, array imageinfo])
    The getimagesize() function will determine the size of any GIF, JPG, PNG, SWF, SWC, PSD, TIFF, BMP or IFF image file and return the dimensions along with the file type and a height/width text string to be used inside a normal HTML IMG tag. Returns an array with 4 elements. Index 0 contains the width of the image in pixels. Index 1 contains the height. Index 2 is a flag indicating the type of the image: 1 = GIF, 2 = JPG, 3 = PNG, 4 = SWF, 5 = PSD, 6 = BMP, 7 = TIFF(intel byte order), 8 = TIFF(motorola byte order), 9 = JPC, 10 = JP2, 11 = JPX, 12 = JB2, 13 = SWC, 14 = IFF. These values correspond to the IMAGETYPE constants that were added in PHP 4.3. Index 3 is a text string with the correct height="yyy" width="xxx" string that can be used directly in an IMG tag.