LoginSignup
2
2

More than 5 years have passed since last update.

PHPビルトインウェブサーバーで簡易Webサーバを立てる

Last updated at Posted at 2018-11-22
  • 以前教えてもらったのにコマンドを忘れてたのでメモしておく。

目的

  • ローカル環境に簡易Webサーバを立てて、HTMLとかJSの動作確認をさくっとしたい

PHPビルトインウェブサーバを使うメリット

  • apache, nginx, xampp, mampを準備しなくてもPHPさえ入っていればコマンド一発で起動できる。

使い方

  • ドキュメントルートにしたいディレクトリに移動して下記コマンドを実行
$ php -S localhost:8000

参照

2
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
2