Blogger Information
Blog 40
fans 0
comment 0
visits 27857
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
composer安装使用和MVC
初见
Original
645 people have browsed it

composer安装

  1. //Composer 下载安装包,windows
  2. // https://getcomposer.org/Composer-Setup.exe

composer

composer 命令

  1. composer -v //查看版本信息
  2. php composer.phar init //初始化
  3. php composer.phar install //安装
  4. php composer.phar update //更新
  5. composer config -g repo.packagist composer https://mirrors.aliyun.com/composer //更改 Composer 的数据源

MVC理解

MVC模式,M是指业务模型,V是指用户界面,C则是控制器,使用MVC的目的是将M和V的实现代码分离,从而使同一个程序可以使用不同的表现形式。
M:模型,model: 跟数据库相关的操作,都放在这里。负责数据操作。一个模型一个类、一个文件、一张数据表
V:视图,view:HTML+CSS+JavaScript,界面相关的代码,都在这里
C:控制器,controller,负责所有的业务处理,转发请求,对请求进行处理,返还给页面

Correcting teacher:PHPzPHPz

Correction status:qualified

Teacher's comments:
Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post