Insert multiple checkbox values

I solve it. public function insertionRow($id){ global $wpdb; $wpdb->query(“INSERT INTO wp_choix_attributs_liste (att_id) VALUES (“.$id.”);”); } In my html with the checkbox. if(isset($_POST[‘sub’])) { foreach ($_POST[‘choixP’] as $id) { self::insertionRow($id); } }

How to order custom user list columns by datetime?

I think you could simplify this a lot by using the pre_get_users hook, instead of working directly with the complicated SQL within the pre_user_query hook. Try something like: add_action( ‘pre_get_users’, function( \WP_User_Query $q ) { $qv = &$q->query_vars; if( isset( $qv[‘orderby’] ) && ‘test_date’ === $qv[‘orderby’] ) { // Custom meta query $qv[‘meta_query’] = [ … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)