First you should probably give us your code so we can understand what you're trying to do and how you're getting it done so far.
You say you want to use PHP to delete a file in a directory on your web server?
Here is a simple usage of the unlink() function that accomplishes that:
For this script, the php file that this code is in must reside in the same folder as the file you want to delete. Let us delete a file called test.html. In this case, whatever directory delete.php and test.html are in, test.html will be deleted from that directory.
Now. Are you trying to delete a file when a user clicks a button or something? Please provide more info so we can further help.