当前位置:网站首页>Phpstudy installs Thinkphp6 (problem + solution)
Phpstudy installs Thinkphp6 (problem + solution)
2022-08-02 03:54:00 【stealth rookie】
One. Installation
Install composer in the software management interface
(I installed version 1.8.5 because the installation of 2.3.3 failed. If I can install 2.3.3, I will install 2.3.3. Because of the error reported later, I still upgraded compose)

Create a website
will generate the following in this folder(The following content needs to be removed first, and then put back after the installation is complete)
Find composer in the management, select the compose version and the php version, PHP >= 7.1.0

Enter cd ../ to return to the previous level
Then composer create-project topthink/think thinkphp
(thinkphp is the domain name of the website created by myself)
Result server composer update reported error: Warning from https://repo.packagist.org: Support for Composer 1 is deprecated and some packages will not be available. You should upgrade to Composer 2. See https://blog.packagist.com/deprecating-composer-1-support/
1. The reason is that the composer version is too old
2. The solution: enter the command composer self-update


Then type cd ../ again
and composer create-project topthink/think thinkphp
The reason for the error is that the thinkphp folder is not empty, so it was mentioned earlier that the contents of the folder should be moved out

After moving out, enter composer create-project topthink/think thinkphp, and then there is no problem!!!
Domain/public
The test installation is complete (remember to move the files that were moved out and move them back!!!)

Update Thinkphp6 core (I didn't update it)
composer update topthink/framework
Note: The directory where the installation and update commands are located is different, and the update must be executed under your application root directory
2. After the installation is successful, the directory structure
- The main change in the directory structure of version 6.0 is that the core framework is included in the
vendordirectory, and then the originalapplicationdirectory becomes theappdirectory. - The directory structure after installation is a single application mode
- In the
macorlinuxenvironment, note that you need to set theruntimedirectory permission to 777
www WEB deployment directory (or subdirectory)├─app application directory│ ├─controller Controller directory│ ├─model Model catalog│ ├─ ... more class library directories│ ││ ├─common.php public function file│ └─event.php event definition file│├─config configuration directory│ ├─app.php Application configuration│ ├─cache.php cache configuration│ ├─console.php console configuration│ ├─cookie.php Cookie configuration│ ├─database.php database configuration│ ├─filesystem.php file disk configuration│ ├─lang.php Multilingual configuration│ ├─log.php log configuration│ ├─middleware.php middleware configuration│ ├─route.php URL and routing configuration│ ├─session.php Session configuration│ ├─trace.php Trace configuration│ └─view.php view configuration│├─view view directory├─route route definition directory│ ├─route.php route definition file│ └─ ...│├─public WEB directory (external access directory)│ ├─index.php entry file│ ├─router.php quick test file│ └─.htaccess for apache rewriting│├─extend extension class library directory├─The runtime directory of the runtime application (writable, customizable)├─vendor Composer class library directory├─.example.env environment variable example file├─composer.json composer definition file├─LICENSE.txt authorization description file├─README.md README file├─think command line entry file边栏推荐
猜你喜欢
随机推荐
ES6数组的扩展方法map、filter、reduce、fill和数组遍历for…in for…of arr.forEach
项目中遇到的问题
如何根据地图上的两个坐标点来确定方向
Function hoisting and variable hoisting
微信小程序云开发如何将页面生成为pdf?
PHP图片压缩到指定的大小
二维码生成API接口,可以直接作为A标签连接
What are the PHP framework?
解决MySQL创建子视图并查看的时候,字符集报错问题
Questions about your resume
[symfony/mailer] An elegant and easy-to-use mail library
16.JS事件, 字符串和运算符
js基础知识
4.表单与输入
微信小程序云开发-证件照的实现
[vite] Failed to parse source for import analysis because the content contains invalid JS syntax.
6.27面试集
17.JS条件语句和循环,以及数据类型转换
js 中this指向
display,visibility,opacity








![微信小程序开发视频加载:[渲染层网络层错误] Failed to load media](/img/24/e12a1312aee28a43428b2ae0bfbe00.png)
