myaac/system/templates/forum.remove_post.html.twig
slawkens 84d502bf10 Fixes regarding csrf + refactor some parts of AAC (guilds + forum)
Replace $account_logged->getPlayers() with getPlayersList()
$_REQUEST['todo'] -> $_REQUEST['post']
$guild_errors -> $errors
2025-05-24 11:42:42 +02:00

13 lines
625 B
Twig

<form action="{{ getLink('forum') }}" method="post" style="display: inline"
{% if post.first_post != post.id %}
onclick="return confirm('Are you sure you want remove post of {{ post.player.getName() }}?')"
{% else %}
onclick="return confirm('Are you sure you want remove thread > {{ post.post_topic}} <?')"
{% endif %}
>
{{ csrf() }}
<input type="hidden" name="action" value="remove_post" />
<input type="hidden" name="id" value="{{ post.id }}" />
<input type="image" src="/images/del.png" border="0" alt="Delete" title="{% if post.first_post != post.id %}Remove Post{% else %}Remove Thread{% endif %}" />
</form>