- Hands-On Full Stack Web Development with Angular 6 and Laravel 5
- Fernando Monteiro
- 90字
- 2021-07-23 19:18:46
Creating controllers
Now it is time to use the artisan to generate our controller, let's see how we can do that:
- Go back to the Terminal window, and type the following command:
php artisan make:controller BandController
After the command, you should see a message in green, stating: Controller created successfully.
- Now, inside app/Http/Controllers, you will see BandController.php, with the following content:
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
use App\Http\Requests;
class BandController extends Controller
{
//
}
As a good practice, always create your controller with the suffix <Somename>Controller.
推薦閱讀
- 解析QUIC/HTTP3:未來(lái)互聯(lián)網(wǎng)的基石
- Modern JavaScript Web Development Cookbook
- 自動(dòng)駕駛網(wǎng)絡(luò):自智時(shí)代的網(wǎng)絡(luò)架構(gòu)
- Truffle Quick Start Guide
- Learning Karaf Cellar
- 互聯(lián)網(wǎng)基礎(chǔ)資源技術(shù)與應(yīng)用發(fā)展態(tài)勢(shì)(2021—2023)
- React:Cross-Platform Application Development with React Native
- 中國(guó)互聯(lián)網(wǎng)發(fā)展報(bào)告2018
- 通信十年:擁抱互聯(lián)網(wǎng)
- 6G無(wú)線(xiàn)網(wǎng)絡(luò)空口關(guān)鍵技術(shù)
- 深入理解Nginx:模塊開(kāi)發(fā)與架構(gòu)解析
- 工業(yè)以太網(wǎng)技術(shù):AFDX/TTE網(wǎng)絡(luò)原理、接口、互連與安全
- 智能物聯(lián)網(wǎng):區(qū)塊鏈與霧計(jì)算融合應(yīng)用詳解
- Migrating to Drupal7
- 加密與解密實(shí)戰(zhàn)全攻略