warning using filesize(), why?
Posted: Wed Dec 10, 2003 4:50 pm
hi, guys this is my very first php program. i am trying to uplod a file ( using multipart/form-data abd check its size.
however i get this warning:
Warning: filesize() [function.filesize]: Stat failed for (errno=2 - No such file or directory) .
i know it must be something very stupid...but what???
however i get this warning:
Warning: filesize() [function.filesize]: Stat failed for (errno=2 - No such file or directory) .
Code: Select all
<?php
require("dblib.php");
db_connect("localhost", "cs318", "cs318", "fall2003");
file=fopen($File,"r");
$size= filesize($file);
echo '<br> size='.$size;
db_disconnect();
?>