Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Pages: 1
When deleting an author
I’m working on a member management system that is using Textpattern for the front end and a CodeIgniter for the back end stuff. I have a separate user manager that I made to accommodate more data for users than the the vanilla admin user area could handle for my needs.
When deleting a user in the txp admin area there’s an option that shows to select another user to be the author in place of the deleted one. Where at in the depths of the TXP code it that happening? Is there a function or chain of functions that run to pull this off that I can look at to see how this is happening? I guess I could always loop over all the txp tables and change the author but i’d like to see how TXP is doing this.
Thanks for any input!
Offline
Re: When deleting an author
ecklesroad wrote:
Is there a function or chain of functions that run to pull this off that I can look at to see how this is happening?
Certainly is. Take a peek in the /include/txp_admin.php
file and look for the function admin_multi_edit
. The assign_assets
portion of the delete case is where it reassigns the current content to the nominated user. Note as well there’s a callback event authors_deleted
if you want to hook into that to do some custom tidying up, and that you can augment or alter the multi edit options by raising a callback on admin_ui > multi_edit_options
.
I have a separate user manager that I made to accommodate more data for users than the the vanilla admin user area could handle for my needs.
And smd_bio couldn’t help? *sob* Is there anything that plugin (or smd_user_manager) could do to ease the burden? Though smd_user_manager does need significantly refactoring for the next Txp release to take advantage of the cool new API.
The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.
Txp Builders – finely-crafted code, design and Txp
Offline
Re: When deleting an author
I’m actually using some parts of smd_user_manager, particularly the permissions and groups. I was using the entire smd_user_manager for a while but I found i had to do too many hacks to make it work with the other things i’m building. Don’t be sad, I think smd_user_manager should be the default install for textpattern over the vanilla one and I have it running on a few other sites.
I’ll take a look at txp_admin.php, I kinda suspected it was in there somewhere. Thanks Stef!Last edited by ecklesroad (2013-03-06 21:41:53)
Offline
Pages: 1