Learning Laravel
Middleware 3 Artisan 3 Eloquent ORM 3 Event Handling 3 Versions 3 Examples 4 Welcome to Laravel tag documentation! 4 Starter Guide 4 Getting Started 4 Laravel Views 5 Chapter 2: Artisan 6 Syntax registered routes filtered by multiple methods 8 Running Laravel Artisan commands using PHP code 9 Creating and registering new artisan command 9 Chapter 3: Authentication 10 Examples 10 Multi Authentication interact with requests before they reach the controllers and can thus modify or reject requests. Artisan Artisan is the command line tool you can use to control parts of Laravel. There are a lot of commands0 码力 | 216 页 | 1.58 MB | 1 年前3Laravel 5.0 Documentation
Configuration iii. Usage iv. Pipelining 8. Artisan CLI i. Overview i. Introduction ii. Usage iii. Calling Commands Outside Of CLI iv. Scheduling Artisan Commands ii. Development i. Introduction to the App namespace. This default namespace can be quickly changed using the new app:name Artisan command. Controllers, middleware, and requests (a new type of class in Laravel 5.0) are now grouped your application is made up entirely of controller routes, you may utilize the new route:cache Artisan command to drastically speed up the registration of your routes. This is primarily useful on applications0 码力 | 242 页 | 1.44 MB | 1 年前3Laravel 5.6 中文文档
.php 文件可能会变得很臃肿,所以,作为使用闭包来授权频道的替代方案,你现在可以使用 频道类。要生成一个频道类,可以使用 Artisan 命令 make:channel。该命令会将新生成的频道类存放到 app/Broadcasting 目录下: php artisan make:channel OrderChannel 接下来,在 routes/channels.php 文件中注册这个频道类: API 消费的资源控制器时,通常你会排除输出 HTML 模板的路由,例如 create 和 edit,要生成不包含这些方法的资源控制器,可以在使 用 Artisan 命令执行 make:controller 时使用 --api 开关: php artisan make:controller API/PhotoController --api 模型序列化优化 在之前版本的 Laravel 中, null 到 Arr::wrap 方法将会返回空数组。 Artisan optimize 命令 之前版本中废弃的 optimize 命令已经被彻底移除。由于 PHP 自身的性能优化,optimize 命令已经不能给应用提供显著的性能提升,所以,你需 要从 composer.json 文件的 scripts 部分移除 php artisan optimize。 Blade 本文档由 Laravel0 码力 | 377 页 | 14.56 MB | 1 年前3Laravel 6.0 中文文档
com 11 如果想要恢复之前版本的 Vue/Bootstrap 脚手架代码,可以安 装 laravel/ui 扩展包,并使用 Artisan 命令 ui 来安装前端脚手架 代码: composer require laravel/ui php artisan ui vue --auth 升级指南 重要更新概览 影响较大 授权资源 & viewAny 字符串 & 数组辅助函数 中,php artisan queue:work 命令会无限 期重试队列任务,从 Laravel 6.0 开始,该命令默认只会重试队列任 务一次,如果你想要强制任务无限期重试,可以通过 tries=0 选项 进行指定: php artisan queue:work --tries=0 此外,请确保你的应用数据库包含了 failed_jobs 数据表,你可以 通过运行 Artisan 命令 queue:failed-table queue:failed-table 来生成这个迁移: php artisan queue:failed-table 请求 Input 门面 影响级别:中等 Input 门面是 Request 门面的翻版,已经被移除,如果你在使 用 Input::get 方法,需要将其调整为 Request::input 方法。所有 其他调用 Input 门面的地方都需要做类似调整。 任务调度 本文档由学院君提供0 码力 | 1442 页 | 14.66 MB | 1 年前3Laravel 3.2 Documentation
......................................................................................... 118 Artisan Commands ....................................................................................... application. You can either download a bundle repository to your bundles directory or use the "Artisan" command-line tool to automatically install them. The Eloquent ORM is the most advanced PHP they are directly integrated into Laravel. You can both generate and run migrations using the "Artisan" command-line utility. Once another member makes schema changes you can update your local copy from0 码力 | 139 页 | 1.13 MB | 1 年前3Laravel 5.2 中文文档
。 认证脚手架 通过多认证驱动,Laravel 可以轻松处理后台用户认证;此外,Laravel 5.2 还提供了便捷 的方式来创建前台认证视图,只需在终端执行如下 Artisan 命令即可: php artisan make:auth 该命令会生成纯文本的、兼容 Bootstrap 样式的视图用于登录、注册和密码重置。该命令 还会使用相应路由更新路由文件。 注意:该功能特性只能在 IronMQ 队列驱动被移动到自己的扩展包中,不再被框架核心支持: http://github.com/LaravelCollective/iron-queue 任务/队列 php artisan make:job 命令现在默认会创建一个队列任务类,如果你想要创建一个同步任 务(非队列),在使用该命令时加上 --sync 选项。 邮件 邮件配置中移除了 pretend 选项,取而代之的,使用 文件重命名为 .env,现在立即这样做。如果应用 key 没有被设 置,用户 Session 和其它加密数据将会有安全隐患。 如果你想要手动生成该 key 的值,使用如下 Artisan 命令即可: php artisan key:generate 更多配置 Laravel 几乎不再需要其它任何配置就可以正常使用了,但是,你最好再看 看 config/app.php 文件,其中包含了一些基于应用可能需要进行改变的配置,比0 码力 | 377 页 | 4.56 MB | 1 年前3Laravel 5.3 中文文档
..................................................................................... 523 12. Artisan Console ........................................................................................ 定 义 之 外 , 现 在 Artisan 命 令 还 可 以 在 app/Console/Kernel.php 文 件 的 commands 方法中以简单闭包的方式定义。在新安装的 Laravel 5.3 应用中, commands 方法会加 载 routes/console.php 文件,从而允许你基于闭包、以路由风格定义控制台命令: Artisan::command('build Laravel 学院致力于提供优质 Laravel 中文学习资源 12 $this->info('Building project...'); }); 更多详情请查看完整的 Artisan 文档。 $loop 变量 注:Laracasts 中有关于此特性的免费视频教程。 当我们在 Blade 模板中循环遍历的时候,$loop 变量将会在循环中生效。通过该变量可以访问很0 码力 | 691 页 | 9.37 MB | 1 年前3Laravel 5.1 中文文档
将登录次数限制引入框架,更多详情请参考认证限制一节。 Laravel 5.1 Laravel 5.1 在 5.0 的基础上继续进行优化和提升,接受 PSR-2 代码风格,新增事件广播 机制,中间件参数,Artisan 优化,等等。 PHP 5.5.9+ 由于 PHP 5.4 将会在今年 9 月份“寿终正寝”,并且 PHP 开发组不会再提供安全更新,Laravel 5.1 要求 PHP5.5.9 或更高版本。PHP5 str_random(10), 'remember_token' => str_random(10), ]; }); 更多关于模型工厂的内容,请查看模型工厂一节。 Artisan 优化 Artisan 命令可以通过使用一个简单的,类似路由风格的“签名”(提供了一个非常简单的接口 来定义命令行参数和选项)来定义: /** * 命令行的名称和签名. * * @var Laravel 学院(LaravelAcademy.org)提供 4 protected $signature = 'email:send {user} {--force}'; 更多关于 Artisan 的内容,请查看命令行一节。 目录结构 为了更好地表达意图,app/Commands 目录被重命名为 app/Jobs,此外,app/Handlers 被合 并到 app/Listeners0 码力 | 307 页 | 3.46 MB | 1 年前3The Laravel Handbook
project in a folder called first . Now go into that folder and run php artisan serve : cd first php artisan serve php artisanis something you’ll use often in Laravel, as it can do 8 While you’re here I recommend you install the extensions Laravel Extra Intellisense Laravel Artisan Laravel Blade Snippets PHP tools for VS Code We have a bunch of folders and a bunch of files. new migration, which is what we will use to create the database table(s) we need to use: php artisan make:migration initial_table_creation 23 This command created the 2023_05_11_080724_initial_table_creation 0 码力 | 111 页 | 14.25 MB | 1 年前3《Slides Dev Web》 03. Laravel
Figure 2: Architecture de Laravel – Documentation officielle16 de Laravel – Cheat Sheet Laravel 817, Artisan18 • Tutoriels – Pour un tuto à jour : bien préciser la version (10) dans votre recherche – Laravel (créer un nouveau projet) 16https://laravel.com/docs/master 17https://quickref.me/laravel 18https://artisan.page/ 19https://laravel.sillo.org/laravel-10/ 20https://www.tutsmake.com/page/1/?s=tutorial+laravel+10 /public 6 Artisan • Laravel’s CLI • Construit avec Symfony Console • Aide aux tâches courantes, ex: $php artisan route:list $php artisan migrate $php artisan make:controller $php artisan list • Extensible290 码力 | 8 页 | 224.34 KB | 1 年前3
共 11 条
- 1
- 2