SuzyM wrote
I tried changing the permissions, even running the
fixperms.php script, but those doesn't work
Were you not able to change the permissions or did you successfully change the permissions but the edit button still doesn't appear (in that case maybe invalidate the cache i.e.
touch conf/local.php. Not sure if that would help, I am also new to dokuwiki...)?
I am not sure if there would be anything else besides permissions that can make the edit button disappear. Since it is really just a text-file. Which operating system do you run?
If I do the following in my data/pages directory, the edit button disappears for the "todo" page of my dokuwiki just as you described. "_www" is the apache default user on Mac Os. I change the ownership of the "todo.txt" file from "_www" to my personal user account "lucas". Apache can then no longer write to the text-file with its "_www" account.
Checking ownership/permissions, everything is fine and owned by _www:
lucas$ ls -l
...
-rw-r--r-- 1 _www staff 918 2 Jan 12:07 sidebar.txt
-rw-r--r-- 1 _www staff 309 21 Dez 13:12 start.txt
-rw-r--r-- 1 _www staff 80 22 Dez 23:00 todo.txt
Changing ownership to my personal account "lucas":
lucas$ sudo chown lucas todo.txt
and checking if it was changed successfully:
lucas$ ls -l
...
-rw-r--r-- 1 _www staff 918 2 Jan 12:07 sidebar.txt
-rw-r--r-- 1 _www staff 309 21 Dez 13:12 start.txt
-rw-r--r-- 1 lucas staff 80 22 Dez 23:00 todo.txt
After this the edit button is no longer visible on my "todo" page.
To fix this I obviously just have to switch the ownership back to the apache user account
lucas$ sudo chown _www todo.txt
or make the file writable for everybody (similar to what the fixperms.php script does) :
lucas$ chmod a+w todo.txt
If I copy a file that belongs to "_www" with my user account "lucas", this will change ownership (even with "-p" flag) because "lucas" does not have permission to set "_www" as the owner. So instead you should use "sudo" or your root account when copying files.