Very quick seeme101.
Thanks... but....
Yes... all of us KNOW we made the field required!!! Here's the huge problem. You require only the first 10 fields to be filled out first. The user fills those out, clicks the email confirm and when the user returns, they are supposed to fill in the rest of their profile, including 10 other required fields. Sometimes a user may return but not fill out the remaining parts of their profile. You want to change something in their profile be it censoring text of a valid profile, changing a membership to a different level, etc. The problem is that I WANT those fields to be required but I have to wait for the user to come back and fill them out before I, the administrator, can edit their profile!!!
Here is the code that needs changing: cp.members.php:
//------------------------------------------------
// Validate the value
//------------------------------------------------
if ($field['field_required'] && ($field['field_type'] != "image" && $field['field_value'] == "" || $field['field_type'] == "image" && (!$field['field_old_value'] && (!isset($field['field_value']['name']) || !$field['field_value']['name']))))
{
$TEMPLATE->set_message("error", str_replace("%1%", $field['field_name'], ($LANG['members']['empty_field'])), 0, 0);
return 0;
}
In this code, I need to figure out the way to make a call to see if the user is not the admin, then perform this validation rule. In templates it looks like this: <!-- IF loggedin_group_id == "1" --> but this is not for php. I have to figure out how you parse the information and I'm looking into it now.
Last edited by slinky (2009-08-17 00:46:40)