Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created February 18, 2019 15:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/067840039348d6f913421bd74279e784 to your computer and use it in GitHub Desktop.
Save parzibyte/067840039348d6f913421bd74279e784 to your computer and use it in GitHub Desktop.
<?php
Route::prefix("administrador")->group(function(){
// Aquí llamar a Route::método como lo solíamos hacer
// podemos pasar parámetros, poner nombres, expresiones
// regulares y todo eso
Route::get("/", function(){
return "Yo respondo a administrador/";
});
Route::get("/escritorio", function(){
return "Yo respondo a administrador/escritorio";
});
Route::get("/ajustes", function(){
return "Yo respondo a administrador/ajustes";
});
Route::get("/cuenta", function(){
return "Yo respondo a administrador/cuenta";
});
Route::get("/factura/{id}", function($id){
return "Yo respondo a administrador/factura y puedo ver que el id es $id";
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment