Jump to content

Archived

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

phporcaffeine

filesize() issue

Recommended Posts


if I type literal text for filesize I can get the file's size. If I reference the filename by string then it returns 0


Example:

//DOES NOT WORK FOR ME

$path = "file.txt";

$size = filesize($path);

echo $size;


//THIS DOES WORK FOR ME

$size = filesize("file.txt");

echo $size;


Anyone have any ideas what I might be doing wrong?

Share this post


Link to post
Share on other sites

×

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.