Forum Moderators: coopster
now i want the administrator to be able to delete the file by typing the message id into an input field, click a button and the entry is being deleted.
i've already solved the problem described above, but when the
unlink($file)
i am using apache 2.0.39
By default, all Apache services are registered to run as the system user (the LocalSystem account). The LocalSystem account has no privileges to your network via any Windows-secured mechanism, including the file system, named pipes, DCOM, or secure RPC. It has, however, wide privileges locally.
That means you need to go to your directory where your files are that you need to delete (I'll use this as an example: "C:\Apache2\myfiles").
Right-click on the directory (myfiles), select "Sharing and Security". Change the owner to LocalSystem, and change the permissions to "Full".
Enable the recursive option if you've got other subdirectories that you want to give the same permissions to.
here's a continuation of the quote from the link above, which you may want to do:
Never grant any network privileges to the LocalSystem account! If you need Apache to be able to access network resources, create a separate account for Apache as noted below.You may want to create a separate account for running Apache service(s). Especially, if you have to access network resources via Apache, this is strongly recommended.
1. Create a normal domain user account, and be sure to memorize its password.
2. Grant the newly-created user a privilege of Log on as a service and Act as part of the operating system. On Windows NT 4.0 these privileges are granted via User Manager for Domains, but on Windows 2000 and XP you probably want to use Group Policy for propagating these settings. You can also manually set these via the Local Security Policy MMC snap-in.
3. Confirm that the created account is a member of the Users group.
4. Grant the account read and execute (RX) rights to all document and script folders (htdocs and cgi-bin for example).
5. Grant the account change (RWXD) rights to the Apache logs directory.
6. Grant the account read and execute (RX) rights to the Apache.exe binary executable.It is usually a good practice to grant the user the Apache service runs as read and execute (RX) access to the whole Apache2 directory, except the logs subdirectory, where the user has to have at least change (RWXD) rights.
HTH,
-MM