请教fopen与fread的问题?
用一个表单(form)去取得fopen要打开文件名时,该文件如果是在服务器目录里的文件都可以打开读出;但是文件要是在客户机子里浏览打开一个文件和读出时就是出错:
Warning: fopen(): open_basedir restriction in effect. File(C:\\Documents and Settings\\user\\My Documents\\xt.txt) is not within the allowed path(s): (D:/usr/www) in D:\usr\www\example\exp29.php on line 72
Warning: fread(): supplied argument is not a valid stream resource in D:\usr\www\example\exp29.php on line 81
这是72行的代码:$fp = fopen($_GET['file'],"r");
这是81行的代码:$read = fread($fp,filesize($_GET['file']));
这是怎么回事呢!请大哥大姐们指路!
谢谢!