Views
4 months ago

laravel_tutorial

Laravel use Event; class

Laravel use Event; class CreateStudentController extends Controller { public function insertform(){ return view('stud_add'); } public function insert(Request $request){ $name = $request->input('stud_name'); DB::insert('insert into student (name) values(?)',[$name]); echo "Record inserted successfully."; echo 'Click Here to go back.'; //firing an event Event::fire(new StudentAdded($name)); } } Step 4: Create an event called StudentAdded by executing the following command. php artisan make:event StudentAdded Step 5: After successful execution, you will receive the following output: 116

Laravel Step 6: The above command will create an event file at App\Events\StudentAdded.php. Copy the following code in that file. App\Events\StudentAdded.php

090-056 Exam BrainDumps are Out - Download and Prepare
Boost Test Library
Real LX0-104 Exam BrainDumps
Rails Conditions - Rails-Konferenz 2009
t T0 - 電気通信大学学術機関リポジトリ C-RECS
The Model View Controller (MVC) - Custom Training Courses ...
blackstar product catalogue single pages 2007 23-03-07:blackstar ...
Pro PHP and jQuery by Jason Lengstorf.pdf - Computer Science ...
Echo ® Brochure - Immucor, Inc.
Order from Australia for Computer Controlled Telephone Exchange
Building Dynamic Websites with MVC