2023-02-26 407
从网上随便搜一下,按步骤做到修改/etc/apache2/httpd.conf
在网上查了半天,我是漏了一句这个
#LoadModule userdir_module libexec/apache2/mod_userdir.so
这是我的,已经改好了
Last login: Thu Aug 11 19:31:58 on ttys003
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2/httpd.conf
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo apachectl restart
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2.httpd.conf
Password:
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2/httpd.conf
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2/httpd-userdir.conf
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2/extra/httpd-userdir.conf
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo apachectl restart
hanxueyingdeMacBook-Pro:~ hanxueying$ vi /etc/apache2/users/hanxueying.conf
[No write since last change]
/bin/bash: wq: command not found
shell returned 127
Press ENTER or type command to continue
[No write since last change]
/bin/bash: wq: command not found
shell returned 127
Press ENTER or type command to continue
[No write since last change]
Press ENTER or type command to continue
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2/users/hanxueying.conf
Password:
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo apachectl restart
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2/users/hanxueying.conf
Password:
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2/users/hanxueying.conf
hanxueyingdeMacBook-Pro:~ hanxueying$ sudo vi /etc/apache2/httpd.conf
#
# This is the main Apache HTTP server configuration file. It contains the
# configuration directives that give the server its instructions.
# See <URL:http://httpd.apache.org/docs/2.4/> for detailed information.
# In particular, see
# <URL:http://httpd.apache.org/docs/2.4/mod/directives.html>
# for a discussion of each configuration directive.
#
# Do NOT simply read the instructions in here without understanding
# what they do. They're here only as hints or reminders. If you are unsure
# consult the online docs. You have been warned.
#
# Configuration and logfile names: If the filenames you specify for many
# of the server's control files begin with "/" (or "drive:/" for Win32), the
# server will use that explicit path. If the filenames do *not* begin
# with "/", the value of ServerRoot is prepended -- so "logs/access_log"
# with ServerRoot set to "/usr/local/apache2" will be interpreted by the
# server as "/usr/local/apache2/logs/access_log", whereas "/logs/access_log"
# will be interpreted as '/logs/access_log'.
#
# ServerRoot: The top of the directory tree under which the server's
# configuration, error, and log files are kept.
"/etc/apache2/httpd.conf" 531L, 20592C
还有在 /private/etc/apache2/users/Your UserName.conf中要写为
<Directory "/Users/YourUserName/Sites/">
Options Indexes MultiViews
AllowOverride None
Require all granted
</Directory>
原文链接:https://77isp.com/post/34518.html
=========================================
https://77isp.com/ 为 “云服务器技术网” 唯一官方服务平台,请勿相信其他任何渠道。
数据库技术 2022-03-28
网站技术 2022-11-26
网站技术 2023-01-07
网站技术 2022-11-17
Windows相关 2022-02-23
网站技术 2023-01-14
Windows相关 2022-02-16
Windows相关 2022-02-16
Linux相关 2022-02-27
数据库技术 2022-02-20
抠敌 2023年10月23日
嚼餐 2023年10月23日
男忌 2023年10月22日
瓮仆 2023年10月22日
簿偌 2023年10月22日
扫码二维码
获取最新动态