Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Hot answers tagged

2

I don't know of a plugin that allows you to do this out of the box, but as you are (/seem to be) comfortable with database manipulation, I've outline below how you can achieve what you want using custom coding. You can run custom queries using the wpdb-class. There are a few posts on WPSE/SO that treat this. Once you've set those up, you can run them on, ...


1

You're missing your where statement. You need to tell wpdb which row it should be updating, otherwise you're looking to insert rather than update. From the $wpdb::update Codex: wpdb->update( string $table, array $data, array $where, array|string $format = null, array|string $where_format = null );


1

You can get the last inserted ID from $wpdb with the insert_id property: $wpdb->insert( ... ); $couponId = $wpdb->insert_id


1

Add this to functions.php add_action('wp_ajax_post_language','post_language'); and then make either of following changes in your code. Because your jquery code is sending FirstNM to server (not FirstName). Therefore in post_language() function, change this line $FirstName = isset( $_POST['FirstName'] ) ? $_POST['FirstName'] : ''; to $FirstName ...


Only top voted, non community-wiki answers of a minimum length are eligible