Maison  >  Article  >  Tutoriel CMS  >  Que faire si le fichier de téléchargement phpcms ne peut pas être écrit

Que faire si le fichier de téléchargement phpcms ne peut pas être écrit

藏色散人
藏色散人original
2020-01-15 09:18:372687parcourir

Que faire si le fichier de téléchargement phpcms ne peut pas être écrit

Que dois-je faire si le fichier de téléchargement phpcms ne peut pas être écrit ?

Que faire si le fichier de téléchargement phpcms ne peut pas être écrit

1. Changez l'utilisateur et le groupe appartenant au répertoire /var/www/html/phpcms en apache

[root@localhost html]# 
[root@localhost html]# pwd
/var/www/html
[root@localhost html]# ls 
index.php  itop  phpcms
[root@localhost html]# 
[root@localhost html]# chown -R apache:apache phpcms/
[root@localhost html]# 
[root@localhost html]#

2. var/ Toutes les autorisations de fichiers dans le répertoire www/html/phpcms sont définies sur 644 et les autorisations de répertoire sont définies sur 755

[root@localhost html]# 
[root@localhost html]# find phpcms/* -type f -exec chmod 644 {} \;
[root@localhost html]# find phpcms/* -type d -exec chmod 755 {} \;
[root@localhost html]#

3 Vérifiez les informations d'autorisation de répertoire et de fichier sous /var. /www/html/phpcms

[root@localhost html]# 
[root@localhost html]# cd phpcms/
[root@localhost phpcms]# ls -lhd 
drwxr-xr-x. 9 apache apache 4.0K 1月   7 17:23 .
[root@localhost phpcms]# 
[root@localhost phpcms]# ls -lh
总用量 60K
-rw-r--r--.  1 apache apache   48 1月   7 00:46 admin.php
drwxr-xr-x.  3 apache apache 4.0K 1月   7 00:46 api
-rw-r--r--.  1 apache apache  991 1月   7 00:46 api.php
drwxr-xr-x. 17 apache apache 4.0K 1月   7 17:23 caches
-rw-r--r--.  1 apache apache  104 1月   7 00:46 crossdomain.xml
-rw-r--r--.  1 apache apache 3.1K 1月   7 00:46 favicon.ico
drwxr-xr-x.  2 apache apache    6 1月   7 17:20 html
-rw-r--r--.  1 apache apache 8.1K 1月   7 19:53 index.html
-rw-r--r--.  1 apache apache  318 1月   7 00:46 index.php
-rw-r--r--.  1 apache apache  523 1月   7 00:46 js.html
drwxr-xr-x. 10 apache apache 4.0K 1月   7 00:46 phpcms
drwxr-xr-x.  7 apache apache 4.0K 1月   7 00:46 phpsso_server
-rw-r--r--.  1 apache apache 3.6K 1月   7 00:46 plugin.php
-rw-r--r--.  1 apache apache  170 1月   7 00:46 robots.txt
drwxr-xr-x.  6 apache apache   51 1月   7 00:46 statics
drwxr-xr-x.  3 apache apache   19 1月   7 17:20 uploadfile
[root@localhost phpcms]# 
[root@localhost phpcms]#

4. J'ai revérifié les "Paramètres d'autorisation des fichiers" et réussi le

Que faire si le fichier de téléchargement phpcms ne peut pas être écrit

Site Web chinois PHP, un grand nombre de gratuits. Tutoriels PHPCMS, bienvenue étude en ligne !

Ce qui précède est le contenu détaillé de. pour plus d'informations, suivez d'autres articles connexes sur le site Web de PHP en chinois!

Déclaration:
Le contenu de cet article est volontairement contribué par les internautes et les droits d'auteur appartiennent à l'auteur original. Ce site n'assume aucune responsabilité légale correspondante. Si vous trouvez un contenu suspecté de plagiat ou de contrefaçon, veuillez contacter admin@php.cn