Giter Club home page Giter Club logo

apache's Introduction

Apache Mac 服务器本地搭建

创建需要存放网站目录

/Users/"用户名" 目录下 创建"Sites" 的文件夹 快速显示隐藏显示系统文件快捷键(command + shift + .)

apache 相关命令

  • 关闭 $sudo apachectl -k stop
  • 开启 $sudo apachectl -k start
  • 重启 $sudo apachectl -k restart

  1. 切换工作目录 cd /etc/apache2
  2. 编辑配置文件 sudo vim httpd.conf
  3. 查找DocumentRoot /DocumentRoot 替换成 /Users/"用户名" 目录下 创建"Sites
DoucumentRoot "Users/用户名/Sites"
<Directory "Users/用户名/Sites">
Options Indexes FollowSymLinks Multiviews
  1. 查找php /php 去掉前面的注释#
  2. 切换工作目录 cd /etc
  3. 拷贝 php 文件 sudo cp php.ini.default php.ini
  4. 重启Apache $sudo apachectl -k restart
本地服务搭建完成

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.