Disable Retain/Delete Posts option when Deleting a user.

Discussion of general topics related to the new version and its place in the world. Don't discuss new features, report bugs, ask for support, et cetera. Don't use this to spam for other boards or attack those boards!
Forum rules
Discussion of general topics related to the new release and its place in the world. Don't discuss new features, report bugs, ask for support, et cetera. Don't use this to spam for other boards or attack those boards!
Post Reply
User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Disable Retain/Delete Posts option when Deleting a user.

Post by Dragosvr92 »

On phpbb 3.0.9 and any previous versions of Olympus. If you want to delete a user from his own Profile page, inside the ACP Page.
It asks you If you wish to Retain or Delete the user's posts.
It would be awesome if it could Detect if the user has any Posts and disable the two options.
As there is no reason to ask you to retain or delete something that doesn't exist.

What do you think?

User avatar
callumacrae
Former Team Member
Posts: 1046
Joined: Tue Apr 27, 2010 9:37 am
Location: England
Contact:

Re: Disable Retain/Delete Posts option when Deleting a user.

Post by callumacrae »

I think that this would be better off in 3.0.10 (it wouldn't require any big changes), but yeah, I agree.

~Callum
Made by developers, for developers!
My blog

User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Re: Disable Retain/Delete Posts option when Deleting a user.

Post by Dragosvr92 »

I agree that also, but when i read the forum description of Olympus it said that Features etc are not to be asked, so it seems to fit here better. If it could get moved to the Olympus forum, please do.

EDIT:

Just looked in the code.

In adm/style/acp_users_overview.html

Add the disabled="disabled" Attribute, to produce:

Code: Select all

<dd><select id="delete_type" name="delete_type" disabled="disabled"><option class="sep" value="">{L_SELECT_OPTION}</option><option value="retain">{L_RETAIN_POSTS}</option><option value="remove">{L_DELETE_POSTS}</option></select></dd>
I guess there could be made a funtion like :
<!-- IF POST_COUNT_0 --> disabled="disabled" <!-- ENDIF -->
I saw theres some PHP code for making the template function around phpBB
Previous user: TheKiller
Avatar on Memberlist 1.0.3

User avatar
naderman
Consultant
Posts: 1727
Joined: Sun Jan 11, 2004 2:11 am
Location: Berlin, Germany
Contact:

Re: Disable Retain/Delete Posts option when Deleting a user.

Post by naderman »

Would be great if you could just report this as an impovement ticket for 3.0 on the tracker. Thanks.

User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Re: Disable Retain/Delete Posts option when Deleting a user.

Post by Dragosvr92 »

Previous user: TheKiller
Avatar on Memberlist 1.0.3

User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Re: Disable Retain/Delete Posts option when Deleting a user.

Post by Dragosvr92 »

I think it may require some Other PHP edits also, to learn how to work without to load anything, when deleteing a user, so you will only press submit, and done ! But that dosnt matter as long as you get the idea, you could do whatever you wish considering you know the phpbb code as your palm :)

Will this be added in phpbb 3.0.10 ?
Previous user: TheKiller
Avatar on Memberlist 1.0.3

User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Re: Disable Retain/Delete Posts option when Deleting a user.

Post by Dragosvr92 »

This was included in 3.0.11-RC1, Thanks :)
Previous user: TheKiller
Avatar on Memberlist 1.0.3

Post Reply