Skip to content
Advertisement

Get values of checkbox values by jquery from modal form window

I can’t find the solution to retrieve checkbox values in my update.php file.

May be these syntaxs is not correct to send the data to the update.php file ?

extralist_text: $editor.find(‘#extralist_text’).val(),

and or

extralist_text: values[‘extralist_text’],

Thank you to help me.

bellow my simplifed code:

JavaScript

Advertisement

Answer

You can use each loop through to iterate through all checkboxes which checked and get its value using $(this).val() and store same in some array so that you can easily pass that values to your backend page.

Demo Code :

JavaScript
JavaScript
User contributions licensed under: CC BY-SA
6 People found this is helpful
Advertisement