php Opening file using file_get_contents or curl through windows auth -


ive got website want open file server. server connected using network drive.

the file uses windows authentication. because of this, using

echo file_get_contents('\\\**.**.local/data/user/*/*.xlsx');

results in

file_get_contents(\\*.*.local/data/user/*/*.xlsx) [function.file-get-contents]: failed open stream: permission denied 

i found similar problem here: how use file_get_contents() retrieve file behind windows nt auth

but cant work. using this:

geturl('\\\*.*.local/data/user/*/*.xlsx','username','password'); 

always results in :

could not resolve host: \\*.*.local 

using

geturl('file://*.*.local/data/user/*/*.xlsx','username','password'); 

gives me

couldn't open file /data/user//.xlsx

what doing wrong?

i think can both use:

geturl('file:////*.*.local/data/user/*/*.xlsx','username','password'); 

or

geturl('file://\\*.*.local\data\user\*\*.xlsx','username','password'); 

Comments

Popular posts from this blog

javascript - IndexedDB error: Uncaught DataCloneError: Failed to execute 'put' on 'IDBObjectStore': An object could not be cloned -

amazon web services - When using Cognito credentials with AWS in a browser (javascript), keep getting "missing credentials" error -

c# - How to set the datatextfield value instead of the value on a drop down list? -