Portal Engine Questions on portal engine and web parts.
Version 4.x > Portal Engine > Issue adding field to User (Community) Profile View modes: 
User avatar
Member
Member
polarwarp-gmail - 5/19/2009 7:56:08 PM
   
Issue adding field to User (Community) Profile
I'm having trouble with adding a field to the user profile.

I was able to add "Status" to the edit form ok - and be able to set the value (have confirmed in the database that it has been saved for the user) - but when trying to make it appear on the Display Profile Alternative Form its just not showing up.

I am noticing that whenever I go to:
Alternative Forms - Display profile
- Fields: Status is in the list but everytime I go to this page the Default visibility is being set to "Display to none". I keep changing this to display to all and it saves it saves ok but reverts back if I click on a different field and then back to status.

Actually if I set it to Display to Authenticated it seems to be staying as this. Is there some kind of overriding rule to explain why I can't show this field to All ?

So yeah in summary why would the Display setting keep being reverted to "Display to none" when I save "Display to all" for this particular user attribute??

User avatar
Kentico Developer
Kentico Developer
kentico_zbysekn - 5/25/2009 4:02:51 AM
   
RE:Issue adding field to User (Community) Profile
Hello,
I wasn't able to reproduce this issue. But I think that the problem is that you have changed the value of field visibility and then forgot to click on OK button so the changes wasn't saved.
Also don't forget that it's important to add your new field into form layout if you are using custom form layout.
Best Regards,
Zbysek Nemec

User avatar
Member
Member
polarwarp-gmail - 6/22/2009 2:44:01 AM
   
RE:Issue adding field to User (Community) Profile
I've been able to reproduce - I add a new field (new attribute). I go to Alternative Forms, I edit the registration form and go to fields. I select my atribute and under field select "Default visibility: Display to All". I click save. It tells me my changes are saved - I go to a different field and then click back on the one I had updated and its defaulted back to display to none.

But I select Display to Authenticated and that doesn't get changed to Display to None. This doesn't help me much as I'm trying to set visibility to all as its a registration form (so the person hasn't logged in).

I'm definately clicking OK and its definately telling me that my changes are saved. But it appears something doesn't like "Display to All" on this new field.

I'm ok with then going to Layout and adding it from the available fields list onto the form.

User avatar
Kentico Developer
Kentico Developer
kentico_zbysekn - 6/29/2009 5:54:56 AM
   
RE:Issue adding field to User (Community) Profile
Hello,
I went through this issue once again and unfortunately I wasn't able to reproduce this issue.
Could you please tell me if you are using clean version of CMS or have you upgraded from lower version? Could you please also give us more details, for example if this is happening for every field, not only newly added fields or if this is happening only for some specific field type?
I'd also like to ask if you are using custom data provider?
Could you please also check if there is any related error in CMSSiteManager ->Administration -> Event log connected with this issue?
Best Regards,
Zbysek Nemec.

User avatar
Member
Member
polarwarp-gmail - 6/29/2009 6:33:44 PM
   
RE:Issue adding field to User (Community) Profile
Hi,

I believe its a clean install of 4.0.

It is happening on both new fields and certain existing ones. With the existing ones - if they're already set to Display to All, then changing it to something and changing back to Display to All saves ok. If they're not included in the editing form and then modified to be shown, they start with the default Display to none - and I can't change it to Display to All. I can only change it to Display to Authenticated. If I save it as Display to Authenticated - and then change it to Display to All. If I save it, go to something else, come back again its back to Display to None.

I have tried a few different field types - so that doesn't seem to be the issue. ie. its consistently not working.

I am not using a custom data provider (using a very vanilla/out of the box install of kentico).

There are no errors in the event log - only updates to the Alternative Form information messages.

I am noticing that there are a lot of Scheduler Run type events - even though I didn't think I had anything scheduled.
"EXCEPTION MESSAGE: Unable to connect to the remote server; STACK TRACE: at System.Net.WebClient.DownloadDataInternal(Uri address, WebRequest& request)
at System.Net.WebClient.DownloadData(Uri address)
at System.Net.WebClient.DownloadData(String address)
at CMS.Scheduler.SchedulingHelper.RunSchedulerRequest(String url)"

If it helps this site is publicly accessible.

User avatar
Member
Member
polarwarp-gmail - 7/1/2009 7:51:51 PM
   
RE:Issue adding field to User (Community) Profile
Hi,

Here is a step by step list of what I'm doing. Hope this helps - I really need to be able to customise the registration form.

1. Go to CMS Desk, Development, System tables
2. Edit User
3. Fields: New Attribute (set attribute name, size, caption. Field type: Textbox) – display attribute in the editing form is ticked.
4. Click OK.
5. Click Alternative forms.
6. Edit Registration Form
7. Fields: Select DailyGoal (my new attribute) – Field Default visibility is set to Display to none. I change this to be Display to All. Click OK. Page saves “The changes were saved.”
8. Select UserId in the left hand list. Select DailyGoal and field Default visibility has been automatically set to Display to none.
9. Click Layout – add a row to the table for DailyGoal label and input fields (Use custom form layout is ticked). Click Save.

I have noticed:
- Display to authenticated stays saved
- Display to friends stays saved
- BUT display to all gets changed to Display to none

Obviously I need to be able to customize the registration form and it needs to be visible to all because they’re not authenticated.

In the event log:
- There is definitely and entry when I change the visibility to Display to all and click ok.

Event ID: 5754 Event type: Information Event time: 7/2/2009 10:46:02 AM Source: Alternative form Event code: UPDATEOBJ User name: administrator IP address: 150.101.163.116 Description: Update Alternative form 'Registration form' Machine name: *** Event URL: /CMSSiteManager/development/SystemTables/AlternativeForms/AlternativeForms_Fields.aspx?classid=59&altformid=1

I am noticing if I click UserId in the left hand list that the event log has this event:

Event ID: 5755 Event type: Error Event time: 7/2/2009 10:46:23 AM Source: Scheduler Event code: Run IP address: Description: EXCEPTION MESSAGE: Unable to connect to the remote server; STACK TRACE: at System.Net.WebClient.DownloadDataInternal(Uri address, WebRequest& request)
at System.Net.WebClient.DownloadData(Uri address)
at System.Net.WebClient.DownloadData(String address)
at CMS.Scheduler.SchedulingHelper.RunSchedulerRequest(String url) Machine name: Event URL:

Well its happening whenever I click a field on the left hand side – is this normal? I have turned off all scheduled tasks (ie. No task has “Task enabled” ticked under Administration, Scheduled Tasks.

Could this be causing my issue?

User avatar
Member
Member
polarwarp-gmail - 7/1/2009 8:15:54 PM
   
RE:Issue adding field to User (Community) Profile
What's even weirder is that despite the field saying its set to Display to None. Its showing to unauthenticated users on the front end today. I'm sure previously it wasn't being displayed and the status was always being changed.




User avatar
Member
Member
polarwarp-gmail - 7/1/2009 8:41:06 PM
   
RE:Issue adding field to User (Community) Profile
OK so it is showing on the Registration form (although in the admin screen its set to Display to None as described above).

It is not showing on the Profile page.
Additional Steps:
1. In Site Manager, Development, System Tables, Edit User
2. Alternative forms, Edit Display profile
3. Layout - add the label and input (although I'd prefer to show a textbox on the registration form, and a label on this page). Save.
4. Its picking up the display to none so not showing me the field. If I set it to Display to Authenticated then it appears (as a textbox). If I try Display it to All it gets reverted back to Display to none after saving and coming back to the field.

so the main issue is still the behaviour where it won't let me display to All
another issue is how I get my new field to be a textbox on the registration form and a label on the profile page - and have it link to the same data value.

User avatar
Kentico Developer
Kentico Developer
kentico_helenag - 7/9/2009 7:57:41 AM
   
RE:Issue adding field to User (Community) Profile
Hello,

I tested it once again according your instructions:

1. Go to CMS Site Manager, Development, System tables
2. Edit User
3. Fields: New Attribute (set attribute name, size, caption. Field type: Textbox) – display attribute in the editing form is ticked.
4. Click OK.
5. Click Alternative forms.
6. Edit Registration Form
7. Fields: Select Test (my new attribute) – Field Default visibility is set to Display to none. I change this to be Display to All. Click OK. Page saves “The changes were saved.”
8. Select UserId in the left hand list. Select Test.
9. Click Layout – add a row to the table for DailyGoal label and input fields (Use custom form layout is ticked). Click Save.


The Test visibility is “Display to all” in the Step 8. If I use this form on live site the Test field is correctly displayed for all users.

Could you please answer me these questions?

1. What value is in the table: CMS_AlternativeForm in FormDefinition column in the row with your Registration form? The empty value means Display to all e.g.:

<field column="test" visibility="" />

2. Does the same issue occur if you change for example the Attribute default value property?

3. Could you please apply the recent hotfix and test it again? You may find the hotfixes here: http://devnet.kentico.com/Bugtracker/Hotfixes.aspx

4. If you re-write the value manually in database is it working correctly?

Regards the text box x label:
You may edit the Display profile Alternative form and change the field type to label here.

Best regards,
Helena Grulichova

User avatar
Member
Member
polarwarp-gmail - 7/12/2009 8:39:31 PM
   
RE:Issue adding field to User (Community) Profile
Hi,

Good news is that upgrading to the final + hotfix version has fixed the bug I was experiencing. I wasn't aware that I was using outofdate stuff. :)

Thanks for your help and for linking the hotfix location (and for support for highlighting I needed to have upgraded my rc version to the full version before applying the hotfix).