Home > PHP Framework > ThinkPHP > Detailed graphic explanation of how thinkphp configures the environment to run

Detailed graphic explanation of how thinkphp configures the environment to run

WBOY
Release: 2022-04-18 17:52:42
forward
4819 people have browsed it

This article brings you relevant knowledge about thinkphp, which mainly introduces related issues about how to set up the configuration environment and run it, including the installation of the PHP development environment, as well as the download and download of thinkphp. Let's take a look at the operation. I hope it will be helpful to everyone.

Detailed graphic explanation of how thinkphp configures the environment to run

Recommended study: "PHP Video Tutorial"

php still has a large market share in the existing market Very high, many small and medium-sized enterprises use PHP for backend and API management and development, including some of the business of many large companies, which are also written and maintained by PHP.

With the development of PHP, many cms (Dreamweaver, Empire, phpcms, discuz, etc.) have appeared, and many PHP frameworks have appeared (Thinkphp, laravel, Yii , Zend, etc.)

Installation of php development environment

First of all, let’s talk about how to install the php development environment, that is, how to run the php file Come on, we will use Windows as an explanation in this section.

Integrated environment download

  1. There is no need to build the environment step by step for local development. Just use the integrated environment directly. Here I recommend using phpStudy
  2. phpStudy The download address is: https://www.xp.cn/, which is very simple and easy to understand. It not only supports Windows, but also has a Linux panel.

Using phpStudy

  1. phpStudy is very simple to use. After installation, it will look like this page.
    You can choose to start apache or nginx. These two are alternatives. If you need to operate the database, enable the database as well.
    Detailed graphic explanation of how thinkphp configures the environment to run

  2. The environment has been Once installed, how do we create a website and make it run normally?
    Detailed graphic explanation of how thinkphp configures the environment to run
    After clicking to create a new website, there will be a pop-up window like this
    Detailed graphic explanation of how thinkphp configures the environment to run
    Domain Name Here, directly fill in a domain name, and you can directly access your website through the domain name you set locally. In the project, a mapping is actually added to the hosts file. When you fill in the domain name, it will create a directory by itself, and just place the program to be run in the generated directory.

  3. At this step, we have already created the environment and project directory. The first creation will automatically put a few files in the directory by default. If they are not needed, just delete them
    Detailed graphic explanation of how thinkphp configures the environment to run
    At this point, the installation of phpStudy and the creation of the project directory are completed

Downloading and running Thinkphp

After we have installed phpStudy, then To download thinkphp

  1. First open thinkphp official website download address: https://www.thinkphp.cn/down/framework.html

  2. These You can download both, select a version, and then click download to download
    Detailed graphic explanation of how thinkphp configures the environment to runDetailed graphic explanation of how thinkphp configures the environment to run

  3. Extract the downloaded compressed package into the project directory you just created
    Detailed graphic explanation of how thinkphp configures the environment to run

  4. In this way, it is not finished yet. We still need to do one more step, that is, adjust the website directory to the public folder, follow the steps below, manage-> Modify->Root directory
    Detailed graphic explanation of how thinkphp configures the environment to run
    Add a /public
    Detailed graphic explanation of how thinkphp configures the environment to run

  5. in the root directory and fill it in when entering the website you just created in the browser If you open the domain name and display this interface, it means that your Thinkphp has been installed
    Detailed graphic explanation of how thinkphp configures the environment to run

Recommended study: "PHP Video Tutorial

The above is the detailed content of Detailed graphic explanation of how thinkphp configures the environment to run. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:csdn.net
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template