easily make your html table content editable with jquery or javascript

Поделиться
HTML-код
  • Опубликовано: 25 окт 2024

Комментарии • 75

  • @roul3688
    @roul3688 5 лет назад +12

    I spent quite awhile looking for a free editable table. This is exactly what I was looking for. Thank you!

  • @xavier4313
    @xavier4313 Месяц назад +1

    Love your enthusiasm mannnn😂...

  • @dungduong6566
    @dungduong6566 3 года назад

    wow, you are master, this is really helpful, im vietnamese and i understand every single word you said! Thank you !

  • @sujitjustinebarwa
    @sujitjustinebarwa 4 года назад

    It was very very useful Thank you very very very much !!!!

  • @Codewithmark
    @Codewithmark  3 года назад

    😀 Subscribe: codewithmark.com/yt-subscribe
    Gift For You: codewithmark.com/gift

  • @luffy4203
    @luffy4203 Год назад

    does the changes also happen in database ?

  • @mariocarrera5063
    @mariocarrera5063 4 года назад

    it works, Thanks a lot for sharing your knowledges

  • @rosecollins4929
    @rosecollins4929 6 лет назад +1

    You might be my new favorite! Thank you!

  • @mythreyiramanan9045
    @mythreyiramanan9045 4 года назад

    Hey mark,do u have the same concept done with plain javascript

    • @Codewithmark
      @Codewithmark  4 года назад

      Unfortunately not because of the compatibility issues with different browsers...

  • @baselplays8
    @baselplays8 Год назад

    thanks i copyed your script but when i edit and save does not save on my hosting !

  • @juanrincon6576
    @juanrincon6576 6 лет назад

    I love this tutorial! Excelent dude!!

  • @phild1537
    @phild1537 6 лет назад

    Great Tutorial ! Thanks a lot for sharing your knowledges.

  • @gilbertbigras6625
    @gilbertbigras6625 5 лет назад

    Thanks. Very useful. I wonder about the random_id function: it is theoretically possible (but I admit with an infinitesimally small chance) that the generator provides the same id. Right? Would possibly need to store all generated id in a temporary array and check that each new one is not member of the array.

    • @Codewithmark
      @Codewithmark  5 лет назад

      Hi Gilbert, depending on the scope of your project and how you are going to use the random id. But during my testing, I pushed it ids up to 100,000 and how duplications were found and it took up to 250 milliseconds. If you are interested in testing random id code to see if it work for you, I have a created a demo page for you : demo.codewithmark.com/2018-12-21-auto-id-check
      Hope this helps you....
      Happy Coding :-)

  • @ashwinigaikwad7630
    @ashwinigaikwad7630 3 года назад

    Can we save only one column value after editing.

    • @Codewithmark
      @Codewithmark  3 года назад

      You sure can... I will be creating a new video soon...
      Happy Coding 😀

  • @yozmari
    @yozmari 6 лет назад

    This is a great tutorial. Thank you so much!!!

  • @jaideepbanerjee616
    @jaideepbanerjee616 2 года назад

    Hi Mark, great tutorial..Thanks. Slightly digressing from the topic. I have the value of ajax_data on my html file in a dictionary format (coming from MongoDB and my python program). On my html file I can access it via {{ajax_data}}. How do I pass this value into my document ready function? If there are any videos or tutorials pls share..would be of great help

  • @kinansharif7055
    @kinansharif7055 7 лет назад

    how could I implement it with using select2 jquery plugin ?
    thanks, Awesome tutorial.

  • @vishwassin
    @vishwassin 5 лет назад

    Good work Mark! Thank you :)

  • @chetannarvekar3539
    @chetannarvekar3539 5 лет назад

    hi Mark, does this approach of dynamically creating the table content work if we have to generate a huge table? say around 10K records

    • @Codewithmark
      @Codewithmark  5 лет назад +1

      Hi Nikhil,
      You can definitely do that.
      The only thing is that on the client side it might take a little while to load up the table depending on the visitors computer. Other than that, it definitely is possible.
      Happy Coding :-)

  • @ngauhunggame
    @ngauhunggame 4 года назад

    it's great, thanks admin

  • @sandeepbhartiya7486
    @sandeepbhartiya7486 6 лет назад +1

    can we save updated data on database

  • @zahratdzair1630
    @zahratdzair1630 5 лет назад

    hi, that was very useful, in my case I'm working on a list of choices for example the client choose t-shirt then he choose the type of material in a select list then he enter the number then after he finish i show a table filed with his choices when he can change the material or the quantity, i wonder how can I make one of the cells a select list, anyone can help , thank you so much

  • @spyros.lefkaditis2071
    @spyros.lefkaditis2071 2 года назад

    does this data saty there if i close the window plz someone help me i want ot create editable table like this that when i change something and leave i see the change when load again the page can someone explain cause with js and html css i havent done it i cant find how i try use local sotrage but still i dont know
    ??

  • @danishsharma7894
    @danishsharma7894 6 лет назад

    Thanks it helped me lot in my comments

  • @mohdarismail3391
    @mohdarismail3391 6 лет назад

    Hii mark, nice work sifu (master), I am looking into you material as my reference

  • @DheaFadlia
    @DheaFadlia 5 месяцев назад

    Wonder how to do this with reactjs

  • @rohitsharma401
    @rohitsharma401 5 лет назад

    your are asowm bro

  • @karen1354
    @karen1354 6 лет назад

    Sir what about if I'm going to get the data from my database and display it to the table, how? Thankyou sir, Im currently doing my Capstone project right now, and I would appreciate if you could help me thankyou .

    • @noah123180
      @noah123180 6 лет назад

      If you have a Database (like MySQL) you need a backend API, from which you can request the data.

  • @jonathanmartinez7557
    @jonathanmartinez7557 5 лет назад

    lo amo senior desconocido

  • @fatimakhan7137
    @fatimakhan7137 5 лет назад

    what syntax did you use?

  • @angelikamariae
    @angelikamariae 4 года назад

    Hi Mark
    I am totally new in Jquery and ajax. what I know how to do is to call my data using pdo and insert it into an html form.
    I have a PDO connection to a mssql database, I was wondering... what is the best practice to fetch the data since you are doing the form with jquery? is it from PHP and then calling the inside the foreach? or inside the tag using some code to call it using jquery? do you have any examples? What you do in the video is exactly what I needed, but now I have to insert my data there ... Thanks in advance.

  • @rajshekar5315
    @rajshekar5315 5 лет назад +2

    Hi Mark
    i have followed your code and i could able to edit the fields but whenever i refresh the page the data is getting erased.
    can you please add something about how to save the edited data back to database?

    • @David-iq1kd
      @David-iq1kd 4 года назад

      ^ I would like to learn how to save back to a database as well.

  • @EVisioNHD
    @EVisioNHD 6 лет назад

    Hey mark i am using Materialize + mysql / php and i have an form wich i need to data be sended to a table like this and the table being editable can you help me ?

    • @Codewithmark
      @Codewithmark  6 лет назад

      Hi Bodhi,
      What have you tried so far?

  • @deepitasaha195
    @deepitasaha195 6 лет назад

    Thank you nice tutorial

  • @lawrencedelacruz4393
    @lawrencedelacruz4393 7 лет назад

    Hii. Can you help me with my thesis? I use php and mysql db and i nees to create like that table but its a grading table.

    • @Codewithmark
      @Codewithmark  7 лет назад

      Hi Lawrencr Thanks for asking the question... Help me better understand... You want to create html table with your data from mysql table. Is that correct?
      If so, are you familiar with jquery ajax function? As that will help you greatly. Here is a quick intro if you don't know it: www.w3schools.com/jquery/ajax_get.asp
      Basically you make an ajax call > your php > mysql table > get all the data you need and send it back to php > and php will send it back to jquery ajax.
      Once you have your mysql table data back in jquery, you can create a html table. Here is a quick video that might help you out: ruclips.net/video/kcCYiA5mWDo/видео.html
      I hope this helps you...
      Happy Coding... :-)
      Mark

    • @lawrencedelacruz4393
      @lawrencedelacruz4393 7 лет назад

      I'm not familiar yet with jquery. I only use bootstraps.

    • @lawrencedelacruz4393
      @lawrencedelacruz4393 7 лет назад

      I have a table from mysql and print it in a php table form. Kinda like yours but its more on grading the students based on the criteria of the teacher.

    • @Codewithmark
      @Codewithmark  7 лет назад

      Can you tell you what are the fields in your mysql table? That way I can create a step by step guide for you to follow to make it easier for you include in your project.....

    • @lawrencedelacruz4393
      @lawrencedelacruz4393 7 лет назад

      Uhm, example activity 1, 2, 3,4. Seatwork 1,2,3,4. Long quiz 1,2,3,4. Exam 1,2,3,4. Like that but i need the result of that to print in the final field -> on the php table.

  • @cananard
    @cananard 6 лет назад

    Excellent !

  • @ninciared9054
    @ninciared9054 7 лет назад

    Doesn't this save after refreshing? If it edits the source code it should?

    • @Codewithmark
      @Codewithmark  7 лет назад

      Hi NinciaRed,
      Help me better understand how do you mean?
      If you are populating your table data on page load via Ajax’s call or simple php echo, then your users make the edits and you update your database via an ajax call. So, next time your page loads it will show the table data with the edits.
      For example, in the video I showed a table which had 4 column, if I edit “Last Name” cell of the first row from “With Mark” to “My Site” and your code updates the last name info via ajax call on your server.
      The next time I reload your page it will show “My Site” for last name cell of the first row.
      I hope this helps you
      Thanks
      Mark
      Happy Coding :-)

    • @ninciared9054
      @ninciared9054 7 лет назад

      Let me explain, I need something like this but the data save in the source file until you edit it again. I need this without the use of MySQL. I tried playing around but I couldn' figure it out really. Thanks!

    • @Codewithmark
      @Codewithmark  7 лет назад

      With the current technology that I know of, doesn’t allow your users to edit the source code file due to the web server and client computer security reasons.
      However, you can try to use client side storage (cookies or localstorage) option to save data and on page reload get the data from there.
      Here is a video training series on how to use localstorage (codewithmark.com/how-to-use-localstorage-like-a-boss) in case if you need help with that.
      Thanks
      Mark
      Happy Coding :-)

  • @massundarpichai8059
    @massundarpichai8059 4 года назад

    how can i add and delete a row?

    • @Codewithmark
      @Codewithmark  4 года назад

      This (codewithmark.com/easily-add-edit-and-delete-html-table-rows-or-cells-with-jquery) should help you out...

    • @massundarpichai8059
      @massundarpichai8059 4 года назад

      @@Codewithmark thank you so much mark

  • @jamalkhan8823
    @jamalkhan8823 5 лет назад

    hey, how to add datepicker in table?

    • @nastycodes
      @nastycodes 5 лет назад

      jsfiddle.net/qhtd3kw4/

  • @johnyo4146
    @johnyo4146 2 года назад

    thx

  • @siddelaharsha8825
    @siddelaharsha8825 5 лет назад

    How can you make fname not editable

  • @adeelrazaazeemi5585
    @adeelrazaazeemi5585 4 года назад +1

    Great code; but with a lot of unnecessary sound effects.

  • @imtiyazshaikh8587
    @imtiyazshaikh8587 6 лет назад

    Hindi me vedio banae

  • @imtiyazshaikh8587
    @imtiyazshaikh8587 6 лет назад

    Please

  • @khrazy5150
    @khrazy5150 6 лет назад

    Jquery is dead bro! The same thing can be done better with Vue or Angular 😆.

    • @Codewithmark
      @Codewithmark  6 лет назад +5

      Hi Keith,
      Based on my own experience, every tool has its own advantages and disadvantages depending on the project you are working on.
      Happy Coding... :-)