Steps to reproduce:
- Create a CCK Text Field
- Widget Type: Text Field
- Global Settings: Number of Values: Unlimited
- Edit a profile which has this field, click the Save button.
- This results in a white screen, and the data is not saved.

In my php error log, I get this:

PHP Fatal error:  Call to undefined function node_form_submit_build_node() in /Users/david/localplay2/sites/all/modules/cck/includes/content.node_form.inc on line 263
PHP Stack trace:
PHP   1. {main}() /Users/david/localplay2/index.php:0
PHP   2. menu_execute_active_handler() /Users/david/localplay2/index.php:18
PHP   3. call_user_func_array() /Users/david/localplay2/includes/menu.inc:348
PHP   4. user_edit() /Users/david/localplay2/includes/menu.inc:0
PHP   5. drupal_get_form() /Users/david/localplay2/modules/user/user.pages.inc:235
PHP   6. drupal_process_form() /Users/david/localplay2/includes/form.inc:119
PHP   7. form_execute_handlers() /Users/david/localplay2/includes/form.inc:409
PHP   8. content_add_more_submit_proxy() /Users/david/localplay2/includes/form.inc:767
PHP   9. content_add_more_submit() /Users/david/localplay2/sites/all/modules/cck/content.module:463

Editing the node directly, instead of on the user profile page, works as expected. The data is saved correctly.

Comments

nadavoid’s picture

I think that there is some weirdness with the form building that might be causing this issue. Currently, the form output looks something like this...

<form action="/user/1/edit/studentprofile"  accept-charset="UTF-8" method="post" id="user-profile-form" enctype="multipart/form-data">
<div>
<form action="/user/1/edit/studentprofile"  accept-charset="UTF-8" method="post" id="node-form">
<div>
stuff...
<input type="hidden" name="changed" id="edit-changed" value="1226615772"  />
<input type="hidden" name="form_token" id="edit-studentprofile-node-form-form-token" value="67e7045c798b58bddb38b40da4e571ab"  />
<input type="hidden" name="form_id" id="edit-studentprofile-node-form" value="studentprofile_node_form"  />
</div>
</form>
<input type="hidden" name="form_build_id" id="form-b2423bd455a7be92b35a718d77dc3f58" value="form-b2423bd455a7be92b35a718d77dc3f58"  />
<input type="hidden" name="form_token" id="edit-user-profile-form-form-token" value="4e69d0b80a2b6742715572be6aaecc6d"  />
<input type="hidden" name="form_id" id="edit-user-profile-form" value="user_profile_form"  />
<input type="submit" name="op" id="edit-submit" value="Save"  class="form-submit" />
<input type="submit" name="op" id="edit-delete" value="Delete"  class="form-submit" />
</div>
</form>

Or, more condensed...

  • form begin
    • form begin
    • hidden fields: form id, etc.
    • form end
  • hidden fields
  • form end

So.. it's like the user profile form is getting mixed with the node edit form. Any thoughts on how we get better control of this? Also, do you think this would be causing the problem with repeating fields?

fago’s picture

fago’s picture

Status: Active » Fixed

this should be fixed with the fix of this issue: http://drupal.org/node/332998#comment-1123924

So please test the next generated development snapshot and make sure to have your menu cache cleared when testing, e.g. hit submit at the admin modules page after updating the module.

nadavoid’s picture

Yes, it is fixed for me. Thanks fago!

Status: Fixed » Closed (fixed)

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