Home JQuery and CRUD Hacks
Post
Cancel

JQuery and CRUD Hacks

Directions

  • Link to Lesson
  • You really should try to answer the 5 questions below this without any help. These are core concepts that you should at least attempt to learn.
  • The update JQUERY function may require a little help but try without first
  • Hacks should only take 20 minutes at most

Question: What are some real life applications of jQuery? Name at least two you can think of

  • Website Animation: Enhances user experience with dynamic and interactive elements.
  • Form Validation: Simplifies client-side validation for user input on websites.

popcorn hack: talk about usage of one of four elements of CRUD from your project in tri 1. Focus on how CRUD was implemented.

  • My project last trimester was a Pocket Therapist, which used AI to detect facial responses and give inspirational quotes in response. My project mainly used the CREATE and READ elements of CRUD. Read was used to fetch all the quote data from the backend and display it on the frontend with javascript. I used the CREATE method to send a post request to the backend so the user could add their own quotes to the database, which would then be used in the pool of quotes that someone might get after getting their facial expression read.

Free Response and MCQ

  1. What does CRUD stand for?
    • Create
    • Read
    • Update
    • Delete
  2. What are the HTTP verbs that are associated with each CRUD action?
    • C - POST
    • R - GET
    • U - UPDATE
    • D - DELETE
  3. What is JQuery?
    • a library that allows us to use some of JavaScript’s built in functions
  4. Match A, B, and C into the JQuery event handler for a data table
    • A: ‘click’
    • B: ‘.delete-btn’
    • C: ‘#data-table’

    $(???).on(???, ???, function() { // code });

$(‘.delete-btn’).on(click, #data-table, function() { //code });

  1. Why do we use JQUERY with CRUD?
    • JQuery is frontend, while CRUD is done on backend. Using the combination of the two allows for efficient and simpler backend and frontend code connections.

Finish the update JQUERY function

  • its all the way at the end, you should see the green comment
  • you can choose to use the two lines I’ve already given or not
IDNameEmailActions

This post is licensed under CC BY 4.0 by the author.

Collectable Lesson

SASS Lesson