This project is read-only.

Pass Flexbox hiddenValue to Controller action

Jun 4, 2015 at 9:55 AM
How do I use the hiddenValue property to have the value posted to the action method of my controller?

Manikandan J
Jun 4, 2015 at 11:54 PM
Did you take a look at the documentation at

That may answer your question.

Jun 6, 2015 at 8:44 AM
I did not find an answer to my question, which is, how to get the hiddenValue field in the post action method in my controller?

Also, can we access the hiddenValue in OnSelect event of flexbox?

Please help.

Manikandan J
Jun 8, 2015 at 3:44 PM
Edited Jun 8, 2015 at 3:45 PM
The hiddenValue is tied to the text input flexbox manages. So, if you have a div with id "myFlexbox", it will generate an input tag where the name = "myFlexbox", and that will be posted to your controller.

In the demos, if you look at example 1, the code is:


which generates the following email (the second line below's "name" attribute will be submitted to the controller):
<div id="ffb1" style="position: relative; z-index: 0; height: 24px;">
  <input type="hidden" id="ffb1_hidden" name="ffb1" value="Albania">
  <input id="ffb1_input" autocomplete="off" class="ffb-input" style="width: 183px;">
  <span id="ffb1_arrow" class="ffb-arrow out"></span>
  <div id="ffb1_ctr" class="ffb" style="width: 212px; top: 30px; left: 0px; display: none;">
    <div class="content" style="height: auto;">
      <div id="AL" val="Albania" class="row ffb-sel">Albania</div>
    <div class=""></div>
Jun 8, 2015 at 3:47 PM
For accessing the hiddenValue in the onSelect event, the documentation covers this, but all you need is:
Jun 13, 2015 at 8:11 AM

I tried the following,
        onSelect: function () {             
            var s = this.getAttribute('hiddenValue');
But, the value of 's' is simply null.

Can someone help me on this?

Manikandan J