Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $('#table tbody').on( 'click', 'td', function () {
- name = $(this).parent().find('td').html().trim();
- stat = $('#table thead tr th').eq($(this).index()).html().trim();
- });
- <div class="modal fade" id="add_new_record_modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
- <div class="modal-dialog" role="document">
- <div class="modal-content">
- <div class="modal-header">
- <h4 class="modal-title" id="myModalLabel">Tickets</h4>
- </div>
- <div class="modal-body">
- <?php
- include("conn.php");
- if(isset($_GET['name'])) {
- $name = $_GET['name'];
- } else {
- $name = "user1";
- }
- if(isset($_GET['stat'])) {
- $stat = $_GET['stat'];
- } else {
- $stat = "open";
- }
- $result = mysql_query("SELECT `id`, `city`, `desc` from `entorno` where `name` = '$name' and stat = '$stat'");
- while($test = mysql_fetch_array($result))
- {
- $id = $test['id'];
- echo"<div class='form-group'>";
- echo"<label>".$test['city']." ".$test['desc']."</label>";
- echo"</div>";
- }
- mysql_close($conn);
- ?>
- </div>
- </div>
- </div>
- </div>
Add Comment
Please, Sign In to add comment