How can I automatically add a comment to a node with rules Can someone help me with this?

I have created a view that gives me a table of certain fields. Now I would like to add a "bulk operation" that lets users add an automatic comment to that specific node.

I have tried to ad a rule (component) and this was the result.

I have activated PHP-filter mode and tried with a component with "Execute custom PHP code". 

The code in the component

&lt;?php
$comment = new stdClass();
$comment-&gt;nid = $node-&gt;nid; // nid of a node you want to attach a comment to  (er stond 1)
$comment-&gt;cid = 0; // leave it as is
$comment-&gt;pid = 0; // parent comment id, 0 if none
$comment-&gt;uid = $user-&gt;uid; // user's id, who left the comment
//$comment-&gt;mail = 'email@example.com'; // user's email
//$comment-&gt;name = 'User name'; // If user is authenticated you can omit this field, it will be auto-populated, if the user is anonymous and you want to name him somehow, input his name here
//$comment-&gt;thread = '01/'; // OPTIONAL. If you need comments to be threaded you can fill this value. Otherwise omit it.
//$comment-&gt;hostname = '127.0.01' // OPTIONAL. You can log poster's ip here
$comment-&gt;created = time(); // OPTIONAL. You can set any time you want here. Useful for backdated comments creation.
$comment-&gt;is_anonymous = 0; // leave it as is
//$comment-&gt;homepage = ''; // you can add homepage URL here
$comment-&gt;status = COMMENT_PUBLISHED; // We auto-publish this comment
$comment-&gt;language = LANGUAGE_NONE; // The same as for a node
$comment-&gt;subject = 'Comment subject';
$comment-&gt;comment_body[$comment-&gt;language][0]['value'] = 'Afgehaald'; // Everything here is pretty much like with a node
$comment-&gt;comment_body[$comment-&gt;language][0]['format'] = 'filtered_html';
//$comment-&gt;field_custom_field_name[LANGUAGE_NONE][0]['value'] = ‘Some value’; // OPTIONAL. If your comment has a custom field attached it can added as simple as this // preparing a comment for a save
comment_submit($comment); // saving a comment
comment_save($comment);
?&gt;


But when I go to the view and execute the operation, he asks for an identifier. But I want him to directly add the comment.

What I mean with the identifier

Can someone help me with this? Or is there another way?
If I'm going right with your requirement that you want an add comment link with every node in view result listing of nodes.

You should add a relation first to that node with comment by using node reference/entity reference by using referece from url widget type. 
Your requirement is same like posting answers node on the specific question node.