Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
By darnok87 on
Hi,
I want to add separate comment form for each node showed in a view.
I used template row using following code:
$comment = new stdClass;
$comment->nid = strip_tags($fields['nid']->content);
$form = drupal_get_form('comment_form', $comment);
print render($form);
Form is showed, but doesnt work properly. When I click on save, instead of saving the comment it redirect me to following url:
comment/reply/35 (in case I try to add a comment for node 35)
Regards