Miki Maine
Miki Maine

Reputation: 350

how to delete file that is not on the server using PHP

I was wondering if I can delete file that is not on the server using PHP

For Example C:\Documents and Settings\a.txt, when the user provides the path?

Upvotes: 0

Views: 110

Answers (1)

FrediWeber
FrediWeber

Reputation: 1099

This is not possible.
It would be a security nightmare if this would be possible.
Imagine that every website could delete every file on your local computer. PHP runs on the server and the file is local. When you upload a file to a website then PHP is able to process that file because the browser sends the file to the server that runs the webserver with PHP.

Upvotes: 1

Related Questions