OnUserProfileBeforeSave
Last updated Aug 15th, 2026 | Page history | Improve this page | Report an issue
Support the team building MODX with a monthly donation.
The budget raised through OpenCollective is transparent, including payouts, and any contributor can apply to be paid for their work on MODX.
Backers
Budget
$194 per month—let's make that $500!
Learn moreEvent: OnUserProfileBeforeSave¶
Fires right before a modUserProfile is saved, in modUserProfile::save().
The profile row holds the email, full name, phone, blocked flags, extended JSON and more — not the modUser login record. Use OnUserBeforeSave when you need the User object itself.
- Service: 1 - Parser Service Events
- Group: User Profiles
Event Parameters¶
| Name | Description |
|---|---|
| userprofile | A reference to the modUserProfile object about to be saved. |
| mode | modSystemEvent::MODE_NEW (new) or modSystemEvent::MODE_UPD (upd), depending on whether the profile is new. |
| cacheFlag | The $cacheFlag value passed into save(). |
See Also¶
Support the team building MODX with a monthly donation.
The budget raised through OpenCollective is transparent, including payouts, and any contributor can apply to be paid for their work on MODX.
Backers
Budget
$194 per month—let's make that $500!
Learn more










