Re: Deleting a read-only file (Windows)

From: Date: Wed, 26 Jun 2002 12:34:25 +0000
Subject: Re: Deleting a read-only file (Windows)
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-103942@lists.php.net to get a copy of this message
unlink() works fine apart from when trying to delete read-only files. Thanks for the suggestion anyway. Neil Lowell Allen wrote:
************************************************************************** This Message Was Virus Checked With : SAVI 3.58 May 2002 Last Updated 14th June 2002 **************************************************************************
From: Neil Freeman <neil.freeman@asa.co.uk> I'm trying to delete a file using PHP's unlink() function (on Windows). This works fine on writable files but fails when trying to delete read-only files. How can I delete read-only files? Is there a function available to change the permissions?
I thought unlink() did not work on Windows. Notes in the manual suggest this for Windows: system("del name.ext"); -- Lowell Allen
-- ---------------------------- Work: neil.freeman@asa.co.uk Home: neil@curvedvision.com Web: www.curvedvision.com ----------------------------

« previous php.general (#103942) next »