亚洲欧美日韩综合系列在线_91精品人妻一区二区_欧美大肥婆一级特大AA片_九色91视频免费观看_亚洲综合国产精品_av中文字幕在线不卡_久久精品色综合网_看黄色视频的软件_无卡无码高清中文字幕码2024_亚洲欧美日韩天堂网

【PHP-Laravel框架學(xué)習(xí)】在ubuntu上配置環(huán)境

來源:WimJimmy 發(fā)布時間:2018-06-30 17:31:22 閱讀量:870

服務(wù)器環(huán)境ubuntu-server-14.04.4

查看系統(tǒng)環(huán)境是否滿足以下條件

<?php phpinfo(); ?>1

OR 
命令行php -m 查看模塊 
對照一下 
- PHP >= 5.5.9 
- OpenSSL PHP Extension 
- PDO PHP Extension 
- Mbstring PHP Extension 
- Tokenizer PHP Extension

局部安裝composer

Installation

First, you need to download Composer into your project folder. Let’s create an empty folder for this purpose in our /var/www Apache web root folder called my_project:

cd /var/www
mkdir projectcd project123

Download Composer into this folder with the following command:

curl -sS https://getcomposer.org/installer | php 
You should see a success message that looks something like this:

All settings correct for using Composer
Downloading...

Composer successfully installed to: /var/www/my_project/composer.phar
Use it: php composer.phar12345

Now if you check in the project folder, you’ll see that only one file has been downloaded: composer.phar - a PHP archive file that can be run from the command line.

更換composer鏡像源

php composer.phar config -g repo.packagist composer https://packagist.phpcomposer.com1

安裝 Laravel 5.1 LTS

php composer.phar create-project laravel/laravel your-project-name --prefer-dist "5.1.*"1

修改apache2 網(wǎng)站目錄

根目錄是public

sudo vim /etc/apache2/site-enabled/000-default.conf1

重啟apache

sudo /etc/init.d/apache2 start 
sudo /etc/init.d/apache2 restart 
sudo /etc/init.d/apache2 stop

訪問localhost 出現(xiàn)“Laravel 5” 就OK了

假如發(fā)現(xiàn)報錯 
failed to open之類的 
設(shè)置下777權(quán)限就好了


原文地址https://blog.csdn.net/WenJimmy/article/details/51152919


標(biāo)簽: PHP
分享:
評論:
你還沒有登錄,請先