Greetings,

I'm using nodeprofile.module and I would like to theme user profile edit form where nodeprofile form is embedded.
We need to display nodeprofile form elements without fieldsets. After we do this the form stops working, values are not saved.

The reason is subform_elemts did something with their names and they were spoiled.

After I manually assigned proper names like this:
$form['profile']['form']['#form']['field_profile_phone']['0']['value']['#name'] = 'profile_node_form[field_profile_phone][0][value]';
everything starts to work correctly.

I understand that you probably change names to avoid name ambiguity (to guarantee unique names) but is it possible to fix this issue?

Comments

fago’s picture

Category: bug » support
Status: Active » Fixed

hm, you should just theme the original form. that should work like usual.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.

ardas’s picture

There is no sense in theming original form because the layout is different.

Example: I have node profile form embedded into user registration form. All elements on node profile form look different from the same elements but on the registration form. There are more elements on registration form and all of them should be layouted in different manner.

I need to have a separate theme function for registration form.