getting_started_with_laravel

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revisionBoth sides next revision
getting_started_with_laravel [03.12.2020 15:43] – [Form validation] Pascal Sutergetting_started_with_laravel [03.12.2020 15:46] – [passing variables from content blades to layouts] Pascal Suter
Line 170: Line 170:
   * even better, there is a ''@error(fieldname)'' blade syntax which will do whatever follows after it if the specified field is invalid   * even better, there is a ''@error(fieldname)'' blade syntax which will do whatever follows after it if the specified field is invalid
  
-here's an example part of a blade with a form that will show some info if the validation fails: +here's an example part of a (bootstrap based) blade with a form that will show some info if the validation fails: 
  
 <code html> <code html>
Line 224: Line 224:
 @extends('layouts.mylaout', [ 'title' => "Details for ".$section->name, 'image' => 'section_details.jpg' ]) @extends('layouts.mylaout', [ 'title' => "Details for ".$section->name, 'image' => 'section_details.jpg' ])
 </code> </code>
-and in the layout you would then simply use ''{{ $title }}'' to echo the title you passed along. +and in the layout you would then simply use <code>{{ $title }}</code> to echo the title you passed along. 
  
 === 2.) create a mini-section === === 2.) create a mini-section ===
  • getting_started_with_laravel.txt
  • Last modified: 04.12.2020 11:44
  • by Pascal Suter