/    Sign up×
Community /Pin to ProfileBookmark

File And Directory Manipulation In PHP

Hello Guys. I´m creating a file system with PHP, where I can upload and delete files, to and from the server. I have the upload part working fine, where I use;

move_uploaded_file($_FILES[‘userfile’][‘tmp_name’], $uploadFile)

to upload the files.

Now does anybody knows how I can delete a file from a specific directory on the server? Thanks

to post a comment
PHP

3 Comments(s)

Copy linkTweet thisAlerts:
@NogDogFeb 25.2005 — [url=http://www.php.net/unlink]unlink()[/url]
Copy linkTweet thisAlerts:
@mitconFeb 25.2005 — I always have to supply a fully qualified directory name to get mine to work. Keep that in mind and there's almost nothing you can't do...

Mitch
Copy linkTweet thisAlerts:
@joao_brauthorFeb 26.2005 — I got it to work just fine guys, thanks a lot.
×

Success!

Help @joao_br spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.9,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...