Version: 1.0.1 (2026-11-01)
Alter the user in the command examples to Chipper
Version: 1.0.0 (2026-10-31)
Command-line batch job that changes the author of one or more SMF posts to another member. It does nothing unless --apply is given.
Run from the forum root, next to Settings.php.
| Purpose | Command |
|---|---|
| Dry run | php reassign_author.php --msgs=101,105-110 --to=Chipper |
| Apply | php reassign_author.php --msgs=101,105-110 --to=Chipper --apply |
| Undo (dry run) | php reassign_author.php --undo=BATCHID |
| Undo (apply) | php reassign_author.php --undo=BATCHID --apply |
Options:
--msgs — message ids (id_msg), comma separated, ranges allowed (105-110).--to — numeric member id, or a member_name / real_name. It must match exactly one member.--settings — path to Settings.php, if it is not next to the script.For each post whose author differs from the target:
{prefix}messages: id_member, poster_name, poster_email are set to the target member's values.{prefix}topics: id_member_started and id_member_updated are re-synced from the topic's first and last message.{prefix}members.posts: the old author loses 1, the new author gains 1, for each countable post. A post is countable if it is approved and in a board that counts posts (boards.count_posts = 0). Guest posts (id_member = 0) have no counter to decrement.{prefix}reassign_author_backup: the original values of every changed post are stored under a batch id (YYYYMMDDHHMMSS).Posts already authored by the target, or not found, are reported and left alone.
--apply a read-only cross-check confirms that every post and every affected topic's first/last poster agree. It prints VERIFY: PASS or FAIL (exit code 2).Nothing else: no SMF source files, no search/log tables.