PHP Development Environment Build--LARAVEL framework, Apache server, git version control, laravelgit_php tutorial

Source: Internet
Author: User
Tags php development environment

PHP Development Environment Build--LARAVEL framework, Apache server, git version control, laravelgit


This article mainly describes the current development environment installation-The backend is PHP, the front-end is built with grunt for automation. This article introduces the environment construction of Apache running PHP under the Windows platform, as well as the installation of Git tools. The writing is a bit rough, but the process is complete, there are shortcomings, please forgive me.

One, Git tool installation

1)https://github.com registered GitHub account

2) Install Phpgit-1.9.5-preview20150319.exe

3) set the user name and email for git:

$ git config--global user.name "Xuhaiyan" $ git config--global user.email "haiyan.xu.vip@gmail.com"

4) Generate SSH key process:

1. See if you already have an SSH key (Bash with Git, don't use cmd): cd ~/.ssh
If there is no key then there will be no such folder, there is a backup to delete

2. Generate the key:

Ssh-keygen -T rsa-c "haiyan.xu.vip@gmail.com"

Press 3 to enter, the password is empty.

Your identification has been saved In/home/tekkub/.ssh/id_rsa.
Your public key has been saved in/home/tekkub/.ssh/id_rsa.pub.
The key fingerprint is:
..................

Finally, two files were obtained: Id_rsa (private key) and id_rsa.pub (public key)

3. Add encryption Key (public key) to Ssh:ssh-add file name

Login to the GitHub account, enter the company project, click Settings/ssh keys/add SSH Key

5) clone the project code to local (assuming the clone code to E:\bd-shop), please fill in the corresponding project code address

git clone git@github.com:xxx.git

Ii. installation of PHP tools

1) Install php Editor:Sublime Text Build 3083 x64 Setup.exe

or install phpstormfor more powerful functions

Third, install wampserver Integration package:wampserver2.5-apache-2.4.9-mysql-5.6.17-php5.5.12-32b.exe( level)

(W:windows system; a:apache server; m:mysql database; p:php language )

Possible error: The following dialog appears:

Workaround: Download vsu4\vcredist_ athttp://www.microsoft.com/zh-CN/download/details.aspx?id=30679 X86.exe and install (note that Wamp server is 32-bit, so x84 is installed, not x64)

If there is no vcredist_x86.exe installation, you can use Nginx to start PHP, in a future article to explain.

Iv. change the apache configuration to set the Apache Server home page as a corporate project:

1)C:\wamp\bin\apache\apache2.4.9\conf\httpd.conf, remove LoadModule rewrite_module modules/mod_rewrite.so ' # ' in front of the comment

2) set the documentroot path to E:\bd-shop\public(based on section 5 Points)

3) will be changed to

Note : The installation is correct, but Apache does not boot ( shown in orange ), the default the the port is already occupied, you need to change the port, and port number is set to 1024x768 after the port, such as 8888 , 8080 and so on, the method is as follows:

in the C:\wamp\bin\apache\apache2.4.9\conf\httpd.conf,

Change Listen 0.0.0.0:80 to Listen 0.0.0.0:8888

Listen [:: 0]:80 changed to Listen [:: 0]:8888

V. Placing vendor and . Env in the project (E:\bd-shop);

Vendor is a dependency package for a project because it is relatively large and slow to download with commands, so it is packaged for immediate use. Can be handled according to the actual situation.

Installation of Node-v0.12.7-x64.msi( to install grunt-cli node. js First )

Seven, put node_modules into bd-shop/resource/assets inside; E:\bd-shop\ enable git bash in resources\assets and write:

Install -G grunt-cli

Install well grunt-cli Run after Grunt command, which is to build ( Note There are no spaces between grunt and -cli ).

Eight, install SQLSRV32. EXE, select the PHP installation directory during installation:C:\wamp\bin\php\php5.5.12\ext; inside the C:\wamp\bin\php\php5.5.12\php.ini file, add the following two lines of code:

extension=php_sqlsrv_55_ts.dllextension=php_pdo_sqlsrv_55_ts.dll

Nine, install sqlncli.msi; install msodbcsql.msi( OBDC Drive)

X. Installation of Laravel

First install composer (composer-setup.exe), then follow the official website http://laravel-china.org/docs/5.0/ Installation inside the steps.

Note : The above path refers to the computer properties / advanced system settings / environment Variables / system Variables /path

http://www.bkjia.com/PHPjc/1114473.html www.bkjia.com true http://www.bkjia.com/PHPjc/1114473.html techarticle PHP Development environment to build--LARAVEL framework, Apache server, git version control, laravelgit This article mainly describes the current development environment to install the backend for PHP, the front-end of the use of grunt from ...

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.