PHP CRUD: Bootstrap Modal: Edit and Update Data into Database in PHP


[ad_1]
https://i.ytimg.com/vi/mh4MVFiMZTM/hqdefault.jpg



Here.. in this video, its done all about how to edit data (fetch data into textbox by its ID) and then update data into Database in PHP using the Bootstrap MODAL i.e POP UP Modal.

Playlist: PHP CRUD-Bootstrap MODAL

Part 1: Insert Data using Bootstrap MODAL

Part 2: Fetch Data using Bootstrap Table

Part 3: Edit and Update Data using Bootstrap MODAL

Part 4: Delete Data using Bootstrap MODAL

Part 5: Search BOX and Pagination using DataTables


Original source


41 responses to “PHP CRUD: Bootstrap Modal: Edit and Update Data into Database in PHP”

  1. Very Nice Tutorial sir, But I have one question. When I try to update one of the data inside the tables, then I tried to change the input one of those forms, then When I click the Update Data button. Nothings Change sir. 🙁 can you help me sir??

  2. Very amazing tutorial that solve a problem of one of my Editing solution. May I ask how I can check or uncheck a checkbox in the Modal based on a value in a database table. Following the part of the code that I'm working on it (Still not working) :

    $('#update_id').val(data[0]);

    $('#username').val(data[1]);

    $('#email').val(data[2]);

    if (data[3].val() == '1')

    {

    $("#admin").prop('checked', true);

    } else {

    $("#admin").prop("checked", false);

    Modal checkbox :

    <div class="form-group form-check">

    <input type="checkbox" name="admin" id="admin" class="form-check-input">

    <label class="form-check-label" for="exampleCheck1">Admin</label>

    </div>

    Thank you.

  3. Sir, you helped me a lot throughout this playlist, but there is one problem for me, everything is working fine, but once i click the edit button, the data is not being fetched, it is like submitting for a new form where all the inputs are blank. BUT, when i tried to inspect, the existing data is present but wasn't shown in the form.
    If you do have any suggestions please comment kind sir

  4. cool tutorial bro, but you should use $(document).on('click', 'className', function(){
    }); insteady of using $('className').on('click', function(){
    });. This will not just show the modal for some minutes then it will dissapear for some browsers. Thanks

  5. How to only display data in popup without input box, if possible please make a video in this playlist to only view data in Pop up modal when click on view button like edit button.

Leave a Reply