Values – `assign_user_to_coauthor`
-
Hi
I want to assign user posts to guest authors (and BTW, then I’ll delete the users) – I’ll use the wp-cli subcommands (once I learn how to use it <grin>!!). “create_guest_authors” is easy because there are no variables AND it does the entire list of users in one pass. “assign_user_to_coauthor” doesn’t seem so straightforward.
2 questions:
1: I’m confused by the data values to use. The code says “$args, $assoc_args”. As far as I can see $args is never referenced (or at least not at this point of development??), which leaves “$assoc_args”. “user_login” seems OK/logical, but what field is used for the value of ‘co-author’.2: Can one do this in bulk? Since “$assoc_args” is an array, would (unique) multiple pairs of user/co-authors result in assignment of posts for all of those pairs; or is this a one-at-a-time process.
Ted
https://www.ads-software.com/extend/plugins/co-authors-plus/
- The topic ‘Values – `assign_user_to_coauthor`’ is closed to new replies.