title: Cannot read property 'value' of null
body: <p>I'm aware there are solutions there on this subject, but i have test this on a test page and works correctly. Basically its a feedback form on a receipt page, if the user logs in again and makes a payment, it doesnt see the form a second time.
  I did this by putting a hiddden field in the DOM, and switching the value from "Y" to "N" in the VB code behind, this all works fine on the test page. But when I code it in the application, it gives me a the error "<strong>TypeError: Cannot read property 'value' of null</strong>". I though at first that the javascript was trying to read the dom, when it hadnt actually rendered yet, so i switched the javascript to the bottom of the page, and even put a timer on it to make sure everything is loaded, still the same result. I cant understand why its doing it in one app, and not the other.</p>
  
  <pre><code>&lt;asp:HiddenField ID="hidfeedback" Value="N" runat ="server" /&gt;
  </code></pre>
  
  <p>Javascript:</p>
  
  <pre><code>//Modal window appears and fades in after 5 secsonds
      $(document).ready(function () {
          setTimeout(function () {
              var getSessionValue = $('#hidfeedback').val();
              if (document.getElementById('hidfeedback').value === "N") {
                  $('#myModal').modal('show');
              }
          }, 5000);
      });
  </code></pre>