[an error occurred while processing this directive]
Forms Processor Advanced Commands
Contents   Index of Commands   Search the Forms Processor Docs   
delete Deletes a specified file.

&delete ("filename");

Examples:

# Can be used in a configuration file as a single command:

&delete("www/junk.txt");


# Or you can test for errors while deleting the file by using a conditional statement:

if (&delete("foobar.baz"))

# returns true if there is an error while deleting the file 

$status="An error occurred while trying to delete the file";

else

# returns false if file was deleted

$status="File successfully deleted";

endif

format screen
$status
.

[an error occurred while processing this directive]