I am trying to create a widget for fivestar module. I have tried the following two methods. Both of them will display the widgets. But when a user clicks on them, neither will save the vote. I am calling this function using drupal_get_form('new_vote', $form).

function new_vote (&$form_state, $form){
  //method 1
    $form['new_vote']['nid'] = array(
      '#type' => 'fivestar',
      '#title' => 'new vote',
      '#target' => 'test1',
      '#axis' => 'test1',
      '#dynamic_target' => 'test1'
    );
   //method 2
    $form['new_vote']['nid2'] = fivestar_form(&$form_state, 'node', '1');

  return $form;
}

Method 2 when a user clicks. It does say that it is saving the vote. But the vote is never saved. But when a user clicks method 1 no save message is displayed.

Any help would be appreciated. Thank you.

Comments

quicksketch’s picture

Status: Active » Closed (fixed)

Sorry you weren't able to receive a response to your question. Closing to clean the issue queue.