Home > Article > Development Tools > Introduction to the installation of ThinkPHP composer and loading of image processing class libraries
The following tutorial is for windows system, the example system uses win7.
composerInstallation
Download the composer installation package (in the group) and click to install.
When ‘composer choose the command-line php’ appears and requires selection, choose to find the installation directory of wanm64. Find bin->php->php7.0.10->php.exe and select it.
Click to install.
After the installation is successful, enter Win R —>cmd to enter the command window, enter composer -v (no semicolon is required), and click Enter. If the following pattern appears, the composer is successfully installed (the following is a partial screenshot):
And composer.json will appear in the project. The sample picture is as follows:
Use composer to install the image processing class library
win R -> cmd to enter the command line interface, enter the following command, modify the composer configuration file, and use the domestic image:
composer config -g repo.packagist composer https://packagist.phpcomposer.com
The example picture is as follows:
Enter the root directory of the project:
Take the project root directory on this computer as an example (D:\run\wamp64\www\hs\hs_store
).
First enter ' D: ' to switch to the D drive directory:
After switching to the D drive, enter ' cd run ' to switch to the D drive run Under contents. And so on,
until you switch to the project root directory.
Enter the following command at this time:
composer require topthink/think-image
to load the image class library.
After the download is completed, you can see three new items in the vendor folder under the project root directory:
Click on the topthink folder to see that the think-img folder exists. At this time, the class library has been successfully loaded.
The above is the detailed content of Introduction to the installation of ThinkPHP composer and loading of image processing class libraries. For more information, please follow other related articles on the PHP Chinese website!