Major version upgrade from 1.0.0 to 2.0.0 including copyright year updates, website URL migration to syspanel.com.br, and comprehensive CSRF token handling improvements. The Twig csrf() helper now returns a complete hidden input field instead of a raw token value, and token generation is now automatic when empty. Session initialization has been centralized in BaseController, and child controllers now properly call parent constructors. CRUD views have been modernized with flexbox layouts and consistent CSRF rendering. Documentation has been expanded with features, requirements, and project structure sections, and donation sections have been added across all pages.
47 lines
1.4 KiB
PHP
Executable File
47 lines
1.4 KiB
PHP
Executable File
{% extends 'layout.twig.php' %}
|
|
|
|
{% block title %}Show Crud Example{% endblock %}
|
|
|
|
{% block content %}
|
|
<div class="container mt-5">
|
|
<h1 class="display-4 text-primary">Twig - Show Crud Example</h1>
|
|
<table class="table table-bordered table-striped">
|
|
<tr>
|
|
<th>ID</th>
|
|
<td>{{ twigexample.id }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Name</th>
|
|
<td>{{ twigexample.name }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Company</th>
|
|
<td>{{ twigexample.company }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Address</th>
|
|
<td>{{ twigexample.address }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Phone</th>
|
|
<td>{{ twigexample.phone }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Email</th>
|
|
<td>{{ twigexample.email }}</td>
|
|
</tr>
|
|
<tr>
|
|
<th>Notes</th>
|
|
<td>{{ twigexample.notes }}</td>
|
|
</tr>
|
|
</table>
|
|
<a href="/twigexample/edit/{{ twigexample.id }}" class="btn btn-warning mr-2">Edit</a>
|
|
<form action="/twigexample/delete/{{ twigexample.id }}" method="POST" class="d-inline">
|
|
{{ csrf()|raw }}
|
|
<button type="submit" class="btn btn-danger mr-2" onclick="return confirm('Are you sure?')">Delete</button>
|
|
</form>
|
|
<a href="/twigexample" class="btn btn-secondary">Back to List</a>
|
|
</div>
|
|
{% endblock %}
|
|
|