Search
 
SCRIPT & CODE EXAMPLE
 

PHP

laravel routing techniques

Route::view('Url','PageName');
//here Url is the call word which pass from url
Route::get('Url',[Controller::class ,'FunctionName']);
//from this route you can access function of specific 
//controller thourgh specific url route
Route::get('Url/{id}',[Controller::class ,'FunctionName']);
//if you want to pass specific id or any thing thorugh route you 
//can use it{id} or{name} or {anything} means anything you want to access
Comment

route() and with() in laravel

Route::get('user/{id}/profile', function ($id) {
    //
})->name('profile');

$url = route('profile', ['id' => 1, 'photos' => 'yes']);

// /user/1/profile?photos=yes
Comment

routing in laravel

Route::view('/welcome', 'welcome');
Route::view('/welcome', 'welcome', ['name' => 'Taylor']);
Comment

Basic routing in laravel

use IlluminateSupportFacadesRoute;
 
Route::get('/greeting', function () {
    return 'Hello World';
});
Comment

PREVIOUS NEXT
Code Example
Php :: php array sum 
Php :: enum artisan codwe 
Php :: php number format comma and decimal 
Php :: Filtering Eloquent collection data with filter 
Php :: php ternary shorthand 
Php :: why storage link do not work in host for laravel 
Php :: php superglobals 
Php :: how to remove keys in subarray php 
Php :: write test case in react native 
Php :: how to change php variable value in javascript 
Php :: php array to object 
Php :: install logger bundle in symfony project 
Php :: php datetime add 1 weeek 
Php :: name of today php 
Php :: php set title dynamically 
Php :: transfer file using file_get_content 
Php :: laravel store array to cache 
Php :: format a number with leading zeros in php 
Php :: can we create linked list in php 
Php :: how to send html table in email body in php 
Php :: Make a Woo required field not required 
Php :: php json response to ajax 
Php :: template literals php 
Php :: file exist php 
Php :: check mobile or email in laravel 
Php :: Laravel Model Create Artisan Commant 
Php :: moodle get course image 
Php :: how to check where function defined in php 
Php :: add json extenstion php 
Php :: laravel log reader 
ADD CONTENT
Topic
Content
Source link
Name
5+3 =