Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

WPDB Insert or if exists Update

$wpdb->update(
    $wpdb->prepare(
        $wpdb->prefix.'item_info',
        array(
            'post_id'       => $post_id,
            'item_stock'    => $item_stock
        ),
        array('post_id' => $post_id)
    )
);
Source by wordpress.stackexchange.com #
 
PREVIOUS NEXT
Tagged: #WPDB #Insert #exists #Update
ADD COMMENT
Topic
Name
7+8 =