RSS Feed/News file_exists issue

Status
Not open for further replies.

ENXF NET

Administrator
Staff member
Administrator
Moderator
+Lifetime VIP+
S.V.I.P.S Member
S.V.I.P Member
V.I.P Member
Collaborate
Registered
Joined
Nov 13, 2018
Messages
24,684
Points
823

Reputation:

I have this code:

Code:

Code:
$dataDir = \XF::app()->config('externalDataPath');
$fileDirectory = $dataDir. '://ill/upload/';
$filename = $signupUsername.'_'.$signupFilename.'.mp3';

if (file_exists($fileDirectory.$filename)) {
 \XF\Util\File::deleteFromAbstractedPath($fileDirectory.$filename); 
}

but for some reason file_exists isn't working. Deleting the file is fine, and I've checked all the paths, so I'm assuming there's a problem with file_exists checking inside the data folder? Any ideas?

Continue reading...
 
Status
Not open for further replies.
Top