RE: zipfile problems - SOLVED

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> -----Original Message-----

<snip>
> 08 	while (false !== ($file = readdir($handle))){
> 09 		$fn = explode(".",$file);
> 10 		if ($fn[1]=="pdf"){
> 11 			echo $inputpath.$file."<br>";
> 12 			$handle = fopen($inputpath.$file,"r");
> 13			$filedata = fread($handle, 
> filesize($inputpath.$file));
> 14 			$zipfile -> add_file($filedata, "dir/".$file);
> 15 		}
> 16 	}

</snip>


Do you need to also close the files you have opened?

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux