0

Hi,
I am saving my excel file in my local directory.

$objWriter->save("C:/test.xls");

How can i delete(only test.xls) this same excel file from my local directory using php. Please try to solve my problem. Thanks in advance.

4
Contributors
3
Replies
4
Views
6 Years
Discussion Span
Last Post by tech.biztech
0

You can use this function:

unlink(test.xls);

I am not sure whether it will work fine with xls file but it's worth giving a try.

0

You can use this function:

unlink(test.xls);

I am not sure whether it will work fine with xls file but it's worth giving a try.

You are right because Deleting a file is done using the PHP unlink command. At one time or accession you will wish to erase some file from your web server and you will need to use the unlink command to do it.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.