This is MARVELOUS!
It seems to work for me, and it was a real simple change to make. In mine, I split up the "if" so that I could post another message instead of the access denied message. I also set it up to work with cb_publicprofile as a radio button, because I thought the message at registration was clearer that way.
instead of
[code:1]
if (!allowAccess( $ueConfig,'RECURSE', userGID($my->id)) || $publicprofile == 0) {
echo _UE_NOT_AUTHORIZED;
return;
}
[/code:1]
I inserted
[code:1] if (!allowAccess( $ueConfig,'RECURSE', userGID($my->id)) ) {
echo _UE_NOT_AUTHORIZED;
return;
}
else if ( $publicprofile == "no"«») {
echo "This user has chosen not to display his or her profile in the directory.";
return;
}[/code:1]
As a result, unless the "no" radio button is checked, the profile is viewable. so if you don't set cb_publicprofile to be required, the profiles default to be viewable.
Since it's a hack, I figured it was silly to make another language variable for the new message. If only it could be done as a plug-in so not to hack the core file?
Thanks so much! I've needed this to get around some other more clumsy processes.
Post edited by: Phleum, at: 2006/08/23 04:31