Forums

Unfortunately no one can be told what FluxBB is - you have to see it for yourself.

You are not logged in.

#1 2019-10-15 07:49:22

Shortik
Member
Registered: 2019-01-11
Posts: 11

Disable the delete function of the first post in topis

Hi,
is there a option to block ALL users (including admin) to delete the first post in a topic?
The second admin of my forum deleted 2 topics by accident in last 2 days and I want to disable this function "at all".
In my case the best way will be some changes in "viewtopic.php" file so I could comment that in case I need to delete whole topic, and after delete the topic I will uncomment that again. Or maybe make it by some parameter I will set to false, delete the topic and set the parameter to true or something like that.

Last edited by Shortik (2019-10-15 07:50:42)


Sorry for my English, I'm not a native speaker. smile

Offline

#2 2019-10-15 09:01:56

Visman
Member
From: Siberia
Registered: 2010-07-10
Posts: 1,381
Website

Re: Disable the delete function of the first post in topis

delete.php file

after

$is_topic_post = ($id == $cur_post['first_post_id']) ? true : false;

add

if ($is_topic_post)
	message('You can not delete this topic.');

Offline

#3 2019-10-15 11:17:43

Shortik
Member
Registered: 2019-01-11
Posts: 11

Re: Disable the delete function of the first post in topis

It works. Thanks a lot!


Sorry for my English, I'm not a native speaker. smile

Offline

Board footer

Powered by FluxBB