When I'm rendering multiple comment forms that have a file field on one page, I can't remove uploaded files except for the first form.
So e.g. I'm rendering two comment forms within a module's function:

$reply_form = drupal_get_form('comment_node_page_form', (object) array('nid' => 1));
$output .= render($reply_form);

$reply_form = drupal_get_form('comment_node_page_form', (object) array('nid' => 2));
$output .= render($reply_form);

On the second one, I'm able to upload a file, but not to remove it. No js errors appear.
Any suggestions on this problem?

Comments

Version: 7.34 » 7.x-dev

Core issues are now filed against the dev versions where changes will be made. Document the specific release you are using in your issue comment. More information about choosing a version.

Status: Active » Closed (outdated)

Automatically closed because Drupal 7 security and bugfix support has ended as of 5 January 2025. If the issue verifiably applies to later versions, please reopen with details and update the version.