I have created new columscolumns in a SQL table 'wp_users'called wp_users
. Those fields are "giodo", "handel" and "regulamin".
What I want to do is to add '1' to each column when a user registers and selects corresponding checkboxes.
I added checkboxes to the form using form_register and then I added those checkboxes to user data with this (here is an example for only one of them):
add_action('user_register', 'myplugin_user_register');
function myplugin_user_register ($user_id) {
if ( isset( $_POST['giodo'] ) )
update_user_meta($user_id, 'giodo', $_POST['giodo']);
}
Can I somehow add their values to the database?