Table of Contents
Relevant learning records of Yii2, download Yii2 (1), record yii2
Home Backend Development PHP Tutorial Yii2 related learning records, download Yii2 (1), record yii2_PHP tutorial

Yii2 related learning records, download Yii2 (1), record yii2_PHP tutorial

Jul 12, 2016 am 08:56 AM
php5

Relevant learning records of Yii2, download Yii2 (1), record yii2

I originally learned the relevant knowledge of Yii1, although I half understood it, but the slight structure is Understood. Now I am using my evening time to learn how to use Yii2. I plan to build a backend management system. I will record it here to avoid forgetting it in the future.

I have read part of the authoritative guide of Yii2 so far. Although the Yiiframework Chinese website is authoritative, compared with the English version, some chapters are missing content, but I can still get a general understanding of what can be done. Please read it carefully when using a certain function. Of course, English is good It is recommended to read the English version, which is relatively new and comprehensive. By the way, I watched the "Stories to Tell with the Yii Framework" series of videos on MOOC.com, and they were very good.

What’s more important is that you need to use Google for FQ. After all, it is a foreign framework and there is relatively little content in Chinese. Most of the answers can be searched in Google. You can use XX-Net here. You can see how to use it yourself. Explain

The first is installation. The Yii2 advanced template is used here, and it is not recommended to use local. Now that you have composer, let’s learn new things:

1. Composer code repository, where you can find everything about Yii2. For example, enter "yiisoft/yii2-app-advanced" in the search box. This is the Yii2 advanced template we are looking for. This code base corresponds to github. You can check the github address in the upper right corner, and then check the instructions on how to install Yii2.

2. Download composer. Of course, due to the wall, composer may not work. You need to use Chinese images here. Some images have stopped updating. As of today (2016/03/27), the composer China full image is available. You should be able to use it according to the instructions.

After the above two components are configured, you should be able to use composer to download Yii2. Problems encountered during installation (under Windows system):

1. The following error will appear:

Fatal error: Call to undefined method Fxp\Composer\AssetPlugin\Package\Version\VersionParser::parseLinks<> ....
Copy after login

You can check this: https://github.com/yiisoft/yii2/issues/9794, that is, delete the "fxp" folder in the relevant directory, and then follow the steps again.

2. When installing under Windows, you may need to enter your github account password and token. This is to register a github account, and then go to "Personal Center"->"Settings"->"Personal access tokens" Just generate a token; if you encounter a situation where the 'git' command is not recognized, you need to download the github client and try it. If it doesn't work, you may need to add git to the environment variable

3. You may encounter this after the installation is complete:

<span>Invalid Parameter &ndash; yii\base\InvalidParamException
The </span><span>file</span> or directory to be published does not exist: E:\www\yii2\yii2test1/vendor\bower/jquery/dist
Copy after login

This may be when you enter a sentence similar to the following:

composer global require <span>"</span><span>fxp/composer-asset-plugin:~1.1.1</span><span>"</span>
Copy after login
The version number behind

is incorrect, resulting in an incorrect directory location. One way is to re-enter the correct version above, and then

composer self-<span>update
composer global update
composer update</span>
Copy after login

Another method is that the currently required files are under vendorbowerbower-asset, so copying the following jquery file to the previous directory can run normally. But it is best to use the first method. I don’t know if the second method has any side effects.

The installation is basically like this. Although it is very laborious, it is also good to learn new methods. Anyway, if you encounter problems, just go to Baidu or Google. I don’t know the specific usage of composer, so I’ll search for it when I need it. That's it, let's go play ball first, Koko!

www.bkjia.comtruehttp: //www.bkjia.com/PHPjc/1114013.htmlTechArticleRelated learning records of Yii2, download Yii2 (1), record yii2. I have previously learned relevant knowledge of Yii1, although it is also I don’t understand it half-heartedly, but I understand a little bit of the structure. Now take advantage of the evening...
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

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
1 months ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
1 months ago By 尊渡假赌尊渡假赌尊渡假赌
Will R.E.P.O. Have Crossplay?
1 months ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

What is the difference between php5 and php8 What is the difference between php5 and php8 Sep 25, 2023 pm 01:34 PM

The differences between php5 and php8 are in terms of performance, language structure, type system, error handling, asynchronous programming, standard library functions and security. Detailed introduction: 1. Performance improvement. Compared with PHP5, PHP8 has a huge improvement in performance. PHP8 introduces a JIT compiler, which can compile and optimize some high-frequency execution codes, thereby improving the running speed; 2. Improved language structure, PHP8 introduces some new language structures and functions. PHP8 supports named parameters, allowing developers to pass parameter names instead of parameter order, etc.

How to change port 80 in php5 How to change port 80 in php5 Jul 24, 2023 pm 04:57 PM

How to change port 80 in php5: 1. Edit the port number in the Apache server configuration file; 2. Edit the PHP configuration file to ensure that PHP works on the new port; 3. Restart the Apache server, and the PHP application will start running on the new port. run on the port.

What is the difference between php7 and php5 syntax What is the difference between php7 and php5 syntax Jul 10, 2023 pm 03:25 PM

The syntax differences between php7 and php5 are: 1. PHP7 introduces strict type declarations, while the type of PHP5 variables is implicit; 2. PHP7 introduces support for scalar type declarations, but PHP5 does not; 3. PHP7 introduces NULL Merge operator, while PHP5 checks whether a variable exists and is not null, you need to use a conditional statement; 4. PHP7 adds a new comparison operator "<=>", but PHP5 does not; 5. PHP7 introduces a new feature anonymous class , while PHP5 does not.

How to solve the problem that php5 is not listening on port 9000 How to solve the problem that php5 is not listening on port 9000 Jul 10, 2023 pm 04:01 PM

Solution steps for php5 not listening to port 9000: 1. Check the PHP-FPM configuration file; 2. Restart the PHP-FPM service; 3. Turn off the firewall or configure port forwarding; 4. Check whether other processes occupy port 9000.

How to change port 80 in php5 How to change port 80 in php5 Mar 21, 2023 pm 04:32 PM

​If you are a website administrator, you may encounter a situation where you need to change the PHP5 port from the default port 80. This process may be a little hurried, but as long as you follow the steps below, it will be easily completed.

How to solve the problem that php5 is not listening on port 9000 How to solve the problem that php5 is not listening on port 9000 Mar 21, 2023 pm 04:32 PM

When using PHP5, some users may encounter the situation that port 9000 cannot be listened to. At this time, we need to perform some configuration and troubleshooting work to solve this problem.

What are the differences between the version of php7 and 5? What are the differences between the version of php7 and 5? Sep 15, 2023 pm 04:11 PM

The differences between the version of php7 and 5 include performance improvements, scalar type declarations, return value type declarations, exception handling improvements, anonymous classes, syntax improvements, new operators, enhanced error handling and the removal of some old features. Detailed introduction: 1. Performance improvement. PHP7 introduces a new Zend engine, named Zend Engine 3.0, which brings significant performance improvement. The performance of PHP7 is approximately twice that of PHP5, mainly through improved memory management. , optimized function calls and exception handling, enhanced garbage collection, etc.

Discuss the syntax differences between PHP7 and PHP5 Discuss the syntax differences between PHP7 and PHP5 Mar 21, 2023 pm 07:10 PM

PHP is a widely used server-side programming language used to develop dynamic websites and applications. In recent years, the release of PHP7 has attracted some attention. PHP7 has many improvements and optimizations over previous versions (such as PHP5). In this article, we will explore the syntax differences between PHP7 and PHP5.

See all articles