title: How to get div whose style is block and values from its hidden input field
body: <p>E.g., I have 5 divs, each one containing an hidden input field. On startup all divs are hidden by css.</p>
  
  <p>CSS -</p>
  
  <pre><code>.divs_nav{
      display:none
  }
  </code></pre>
  
  <p>Divs -</p>
  
  <pre><code>&lt;div id="1" class="divs_nav"&gt; Div - 1
      &lt;input type="hidden" id="id_qno-1" class="class_qno" value="Question-101" /&gt;
  &lt;/div&gt;
  &lt;div id="2" class="divs_nav"&gt; Div - 2
      &lt;input type="hidden" id="id_qno-2" class="class_qno" value="Question-102" /&gt;
  &lt;/div&gt;
  &lt;div id="3" class="divs_nav"&gt; Div - 3
      &lt;input type="hidden" id="id_qno-3" class="class_qno" value="Question-103" /&gt;
  &lt;/div&gt;
  &lt;div id="4" class="divs_nav"&gt; Div - 4
      &lt;input type="hidden" id="id_qno-4" class="class_qno" value="Question-104" /&gt;
  &lt;/div&gt;
  &lt;div id="5" class="divs_nav"&gt; Div - 5
      &lt;input type="hidden" id="id_qno-5" class="class_qno" value="Question-105" /&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>In the real code, number of these divs may reach upto 500 or more and their appearance is defined by Previous, Next navigation Buttons. But to demonstrate here, I am doing this by 5 buttons and jquery.</p>
  
  <p>Buttons -</p>
  
  <pre><code>&lt;input type="button" id="btn-1" value="1" class="divButton" /&gt;
  &lt;input type="button" id="btn-1" value="2" class="divButton" /&gt;
  &lt;input type="button" id="btn-1" value="3" class="divButton" /&gt;
  &lt;input type="button" id="btn-1" value="4" class="divButton" /&gt;
  &lt;input type="button" id="btn-1" value="5" class="divButton"/&gt;
  </code></pre>
  
  <p>Jquery -</p>
  
  <pre><code>$('.divButton').click(function() {
      var blockId = this.value;
      document.getElementById(1).style.display = "none";
      document.getElementById(2).style.display = "none";
      document.getElementById(3).style.display = "none";
      document.getElementById(4).style.display = "none";
      document.getElementById(5).style.display = "none";
      document.getElementById(blockId).style.display = "block";
      });
  </code></pre>
  
  <p>Now comes the real <strong>Question</strong> - I have an button outside above mentioned Divs, which is always visible. <strong>What I want is, value of hidden input field from currently visible div</strong> (on this button click).</p>
  
  <pre><code>&lt;input type="button" id="activeQno" value="Get Active Q. No." class="activeQno"/&gt;
  </code></pre>
  
  <p>I am completely stuck here. What should be the jquery to get the desired info?</p>
  
  <p><a href="http://jsfiddle.net/atultiwari/V7CFU/8/" rel="nofollow">Link of JsFiddle of this e.g.</a></p>
  
  <p>Thanks. Regards,</p>