0

I would like to modify the value of my VBO checkboxes but can't figure where to hook in.

<input name="objects[selection][1]" id="edit-objects-selection-1" value="1" class="form-checkbox select" type="checkbox">

becomes

<input name="objects[selection][1]" id="edit-objects-selection-1" value="1-XXX" class="form-checkbox select" type="checkbox">

2 Answers 2

1

I guess it should be form, so you can try the following on VBO page, if it workds.

   function  mymodule_form_alter(&$form, &$form_state,$form_id) {
      dpm($form_id);
    }
1
  • I should have mentioned that I've looked at $form in hook_form_FORM_ID_alter() and there is $form['objects']['#sets'][$i]['id'] which contains the value that it uses to build the checkbox value. But its used elsewhere and I can't modify at that source.
    – Russell
    Oct 2, 2013 at 20:13
0

The value I needed was in the $context variable in the action :|

EDIT
I didn't need to change the checkbox value because the value I wanted was in the actions $context variable.

1
  • Hello and welcome. It's nice you found a way to success, but could you provide a code sample or more detailed explanation? Now your answer doesn't look like an answer to the question - in question you ask for hooks, in answer you talk about value, and it's confusing.
    – Mołot
    Oct 3, 2013 at 15:48

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.