troubleshooting Question

Bootstrap Modal and ASP QueryString

Avatar of Bob Schneider
Bob SchneiderFlag for United States of America asked on
JavaScriptASPBootstrap
4 Comments1 Solution14 ViewsLast Modified:
I am implementing a bootstrap modal to edit individual records in a table.  I need to pass a unique id to the modal when it opens so I can query the MS Sql Server db to pull/display the data to edit.  Not sure how to do this.  Code below.  Note that the modal opens correctly.  Just need to populate it with data so I can edit it.  If there is a better approach, I am open to it, but I really like the way the modal opens.

Trigger:
<a data-toggle="modal" href="#myModal" class="button"><%=Items(1, i)%></a>

Modal:
<div class="modal fade" id="myModal" role="dialog">
    <div class="modal-dialog modal-lg">
      <div class="modal-content">
        <div class="modal-header">
          <button type="button" class="close" data-dismiss="modal">&times;</button>
          <h4 class="modal-title">Edit Item</h4>
        </div>
        <div class="modal-body">
          <p>This is a large modal.</p>
        </div>
        <div class="modal-footer">
          <button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
        </div>
      </div>
    </div>
  </div>



Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 4 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 4 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros