![]() |
Blade Template in Codeigniter - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: External Resources (https://forum.codeigniter.com/forumdisplay.php?fid=7) +--- Forum: Addins (https://forum.codeigniter.com/forumdisplay.php?fid=13) +--- Thread: Blade Template in Codeigniter (/showthread.php?tid=80148) |
Blade Template in Codeigniter - aididalam - 09-20-2021 A library for rendering *.blade.php file in CI. This can render .blade.php in Codeinteger and can convert Strings into blade templating system.
You can use those shorttags to make the template and this will prevent you to write <?= $data ?> or <?php echo $data ?> everytime. You can just use {{$data}} to render your data. You can also conver strings into blade view without any blade.php file. This is so usefull when you store some template in Database with {{$variable}} . Just pull the template from db and pass the variable data it will compile and return you the template without any blade.php file and then you can render it as a string in any where. Common Scenario: You save a email template in you database like this: Hello {{$first_name}} {{$last_name}} ! Reset your password by clicking following link <a href="{{$url}}">Clcik Here</a> Rendering this in blade in compicated but with this library you can render this in a minute. This library avaiable in github. Blade Template in Codeigniter RE: Blade Template in Codeigniter - Reiji - 02-01-2024 This seems to be very useful. Thank you for sharing. |