This is the place to report bugs and get support. When posting in this forum, please always provide as much detail as possible.
Please do not report problems with a custom build or custom code in this forum. If you are producing your own build from the source code and have problems or questions, ask in the developer forum, do not report it as a bug.
When posting in this forum, please try to provide as many relevant details as possible. Particularly the following:
I created a custom profile property as explained in the documentation. This new property is visible in edit and manage mode if I don't use the onlyVisibleForRoles attribute. I made several tests and this attribute doesn't seem to work. Here are the results of my tests :
Connected with Admins role, it's ok:
Connected with Authenticated Users, there are some bugs :
Why the custom property is visible for the Authenticated Users role while its onlyVisibleForRoles attribute is set to Admins ?
I hope my question is understandable, if not tell me, I'll try to be clearer.
Has anybody had the same issue ? Maybe my explanation is not clear ?
To recap, although the onlyVisibleForRoles is set to "Admins" for my custom field in my CustomProfile.config, when I log in with role "Authenticated Users", I still can see my custom field.
I found the code where I could modify it but maybe it's not a bug and I don't use this parameter as it should ?
My mojoPortal version : 126.96.36.199 MSSQL
Thanks for your anwser.
It would be easier to answer if you post your property definition so I can see all the settings on it.
Excuse me, I haven't thought to post my properties definition, here it is :
labelResourceKey="Téléphone pro (visible and available for role 'Admins')"
labelResourceKey="Téléphone mobile (available for role 'Admins')"
labelResourceKey="Téléphone personnel (visible for role 'Admins')"
I tried with a custom role and it doesn't seem to work too...
If you only want it visible to certain roles then you should not have this:
Also you should put a semi colon after role names like Admins;
Hope it helps,
Thanks for your answer Joe, here is my new property definition :
labelResourceKey="Tlphone personnel (visible for role 'Admins')"
I have deleted the visibleToAuthenticated="true" and put a semi colon after role name but my custom property is still visible when connected with a user without Admins role.
Could you send me a customprofile.config that works, for trying it and see what happens ?
Is the user you connect as looking at his own profile or someone else's profile? He will see it on his own profile with visibleToUser="true" but he should not see it on someone else's profile.
The user I connect as is looking at someone else's profile...
Ok, I will investigate this as a bug.
Ok, thank you Joe.
If it can help you, I think the pb is at line 248 of ProfileView.aspx.cs...
I was able to produce the problem using your property definition and was able to fix it.
This will be fixed in the next release and the fix will be in svn trunk by tonight sometime.
ok, thanks a lot for the quick answer !