wp_update_post onclick button using ajax

No no no! Never POST or link directly to a custom PHP file – WordPress won’t be loaded, and to load it manually yourself means making huge assumptions about the file hierarchy.

Use the ajax API, which exists specifically for this reason:

$.ajax({
    url: "<?php echo esc_js( admin_url( 'admin-ajax.php' ) ) ?>",
    type: "POST",
    data: {
        action: "update_button",
        button:  $( this ).val()
    }
});

And for your PHP:

function wpse_227396_update_button() {
    switch ( filter_input( INPUT_POST, 'button' ) ) {
        case 'Save News':
            add_content(303);
            break;
        case 'Save About Us':
            add_content(75);
            break;
        case 'Save Contact':
            add_content(30);
            break;
    }
}

add_action( 'wp_ajax_nopriv_update_button', 'wpse_227396_update_button' );
add_action( 'wp_ajax_update_button',        'wpse_227396_update_button' );