admin管理员组

文章数量:1122846

I made a survey application. The survey works successfully when I email it to 4,000 users. However, when I send it via SMS, there is an error in the numbers.

The reason is that when I send an e-mail, not all users enter data at the same time. However, when I send it via SMS, there are many entries at the same time, I have to read the postmeta, update it without changing it, and then move on to the next record. What do you suggest, some of the code is below. Thank you very much to everyone who is interested.

Option A;

function uD_Option_A_Increase(){
//Read
$uD_Option_A= get_post_meta( $uD_post_ID, 'uD_Option_A_Value' );
//Increase
$uD_Option_A_Plus= $uD_Option_A + 1;
//Update
update_post_meta( $uD_post_ID, 'uD_Option_A_Value', $uD_Option_A_Plus );
}

本文标签: post metaI read the postmeta and update it without changing itthen move on to the next record