PHP fopen() can't function -
i facing problem php fopen() read files.
the error :
warning: fopen(\\192.168.183.28\digi_prog\m10\test1\p001.txt): failed open stream: invalid argument in c:\xampp\htdocs\digi\index.php on line 72
and php code :
echo $fs = fopen("\\\\192.168.183.28\\digi_prog\\m10\\test1\\p001.txt","r");
strangely, when try open url, it's opened. make sure, file exist.
any advice?
if read docs see that
resource fopen ( string $filename , string $mode [, bool $use_include_path = false [, resource $context ]] )
where
filename of form "scheme://...", assumed url , php
i suggest use following
fopen('http://192.168.183.28/digi_prog/m10/test1/p001.txt','r')
or use file_get_contents (after making sure allow_url_fopen set 1)
Comments
Post a Comment