Jump to content

How do I make unlink() into an active link?


pneudralics

Recommended Posts

How do you mean? You could make a link which has the name of the image as a query string, then perform some testing on the received string to ensure that the file exists. Once that has been completed you can use unlink() to remove the file.

 

if(file_exists("files/" . $_GET['delete'])){
unlink("files/" . $_GET['delete']);
}

 

Just a simple example.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.