Skip to:
Content

Opened 10 years ago

Closed 8 years ago

Last modified 8 years ago

#1236 closed enhancement (fixed)

[patch] Custom validation methods for profile field data

Reported by: swinton Owned by: johnjamesjacoby
Milestone: 1.5 Priority: minor
Severity: Version:
Component: Core Keywords: has-patch
Cc:

Description

It would be nice if the xprofile component provided a means of validating profile field data using a custom function.

For example, a profile field 'Post code' should only contain post codes.

This could be achieved by applying a filter on the value returned from is_valid_field in BP_XProfile_ProfileData.

3rd party plugins could then validate the profile data as required.

A suggested patch is attached.

Attachments (1)

bp-xprofile-classes.patch (375 bytes) - added by swinton 10 years ago.

Download all attachments as: .zip

Change History (8)

#1 @DJPaul
10 years ago

  • Keywords has-patch added

#2 @DJPaul
9 years ago

  • Keywords has-patch removed
  • Milestone changed from 1.2 to 1.3

xProfile is to be reviewed and updated in 1.3. Too much ha changed in the 4 months since this was posted for this ticket to be applicable.

#3 @johnjamesjacoby
9 years ago

  • Component set to Core
  • Owner set to johnjamesjacoby
  • Status changed from new to assigned

Assigning to myself for xprofile 1.3 make-over.

#4 @paulhastings0
9 years ago

  • Summary changed from Custom validation methods for profile field data to [patch] Custom validation methods for profile field data

#5 @boonebgorges
8 years ago

  • Keywords has-patch added; xprofile validation filter removed

+1 on this idea and on the patch's simple solution. Mr JJJ, you make the final call, since it's assigned to you.

#6 @johnjamesjacoby
8 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

(In [3395]) Fixes #1236 (branch) props swinton

#7 @johnjamesjacoby
8 years ago

(In [3396]) Fixes #1236 (trunk) props swinton

Note: See TracTickets for help on using tickets.