• Saturday , 4 April 2020

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

Code Canyon
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

3d Ocean

Related Posts

41 Comments

  1. James Emperado
    February 18, 2020 at 17:20

    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. Saguira Manggis
    February 18, 2020 at 17:20

    Do you have source code

  3. Rogue War
    February 18, 2020 at 17:20

    How about when calling an image in td . It is not showing.

  4. Muhammad Ilham Robani
    February 18, 2020 at 17:20

    when i click edit button it doesn't do anything , plz help me sir

  5. pritam - tech
    February 18, 2020 at 17:20

    But sir how to show the image in popup model
    Please tell me
    Please Sir

  6. PMY Channel
    February 18, 2020 at 17:20

    Why you did not share link of bootstrap that you use?

  7. LetEat Vlog
    February 18, 2020 at 17:20

    I have issue with java-script,
    $('#update_id').val([0]);

    $('#first_name').val([1]);

    $('#last_name').val([2]);

    $('#id_number').val([3]);

    $('#username').val([4]);
    it appear number 1 , 2, 3, 4, in the input field not the value from table. Please help me !!!

  8. Novita Asfandar
    February 18, 2020 at 17:20

    hi sir, I tried to make it but when updating data, the updated data is not stored in the database. why is that?

  9. Attitude Bhakiro
    February 18, 2020 at 17:20

    hi, thank you for this tutorial, Unfortunately i encountered a problem. The popup modal is running well on the first 10 rows of my table then the 11th onward are not running. How can i fix?

  10. Hadiwinata Kuo
    February 18, 2020 at 17:20

    the phone number didn't pop up because there are space characters, i think

  11. Tifiko 08
    February 18, 2020 at 17:20

    What the meaning of “Children”? is it database?

  12. elie Patient
    February 18, 2020 at 17:20

    thank you brother you saved my life too

  13. SYED IMRAN ALI
    February 18, 2020 at 17:20

    Thx

  14. johnny pozo
    February 18, 2020 at 17:20

    You saved my life :´)

  15. Padmanabam Karri
    February 18, 2020 at 17:20

    Can u make a video on multiple images insert into single column and display, update, delete using ajax php

  16. Padmanabam Karri
    February 18, 2020 at 17:20

    Excellent video

  17. Jedrek
    February 18, 2020 at 17:20

    will this do the update without a full page reload?

  18. Fenomer Arango
    February 18, 2020 at 17:20

    SI funciona pero si tienes paginacion ya no deja de funcionar alguna solucion a este problema!!!

  19. RNG Gaming
    February 18, 2020 at 17:20

    Hi how about fetching the selected value from database into the drop down box?

  20. Muhammad Asim
    February 18, 2020 at 17:20

    That is amazing. best tutorials. There are script alert messages in your code but they don't seem to appear when the data is deleted or updated.

  21. Leonhart1982
    February 18, 2020 at 17:20

    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.

  22. Lokcies
    February 18, 2020 at 17:20

    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

  23. Shasi Dash
    February 18, 2020 at 17:20

    dear sir. plz provide source code. it will be helpful for us(beginners)

  24. Walid Khan
    February 18, 2020 at 17:20

    Great Work brother.Helped alot
    Source Code ?

  25. Michael Kisingi
    February 18, 2020 at 17:20

    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

  26. Andi ILLank
    February 18, 2020 at 17:20

    Where i can download the file of this tutorial from begining to search part

  27. JM Felicilda
    February 18, 2020 at 17:20

    my data didn't fetch on my modal. and when i inspect it shows that the "Uncaught SyntaxError: Unexpected token . ". plss help

  28. Indra Sudarsono
    February 18, 2020 at 17:20

    thanks, it works

  29. White Magic
    February 18, 2020 at 17:20

    code please :github

  30. LUIS ANGEL MENDOZA CHATE
    February 18, 2020 at 17:20

    Source Code Dislike !!!!!!!

  31. ZABARMAST PAKISTAN
    February 18, 2020 at 17:20

    during the process of edit i can't find data in the form

  32. TECH TIP
    February 18, 2020 at 17:20

    Source code sir

  33. Habeas Ventures Inc.
    February 18, 2020 at 17:20

    thank you for your efforts! but i have a question. i tried using the lates bootstrap version and modal won't work. help please ^^

  34. Wc Yap
    February 18, 2020 at 17:20

    pls help.. edit modal didnt popup after i clicking the editbtn

  35. Cybernet
    February 18, 2020 at 17:20

    Unable to fetch data into edit modal form… Didn't work for me..

  36. Mohamed Aharrat
    February 18, 2020 at 17:20

    Every thing is working just fine for me, thank you for your efforts.

  37. Power Khan
    February 18, 2020 at 17:20

    How to update just only one data? Please upload tutorial sir

  38. Dinesh Subramanian
    February 18, 2020 at 17:20

    hi data didnot come in modal show this error Uncaught ReferenceError: td is not defined

  39. Crisen Recto
    February 18, 2020 at 17:20

    Edit modal didn'tpop up

  40. M K
    February 18, 2020 at 17:20

    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 Comment

You must be logged in to post a comment.