link the plugins at both ends so that each can discover a post that was imported/exported to/from the other and keep track of updates accordingly
This commit is contained in:
parent
ef53c72a70
commit
64b71a231b
@ -59,14 +59,11 @@ function post_to_red_post($post_id) {
|
|||||||
$post = get_post($post_id);
|
$post = get_post($post_id);
|
||||||
|
|
||||||
if (isset($_POST['post_to_red'])) {
|
if (isset($_POST['post_to_red'])) {
|
||||||
update_post_meta($post_id, 'post_to_red', 1);
|
update_post_meta($post_id, 'post_to_red', '1');
|
||||||
} else {
|
}
|
||||||
update_post_meta($post_id, 'post_to_red', 0);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// if meta has been set
|
// if meta has been set
|
||||||
if (get_post_meta($post_id, "post_to_red", true) == 1) {
|
if (get_post_meta($post_id, "post_to_red", true) === '1') {
|
||||||
|
|
||||||
$user_name = post_to_red_get_acct_name();
|
$user_name = post_to_red_get_acct_name();
|
||||||
$password = post_to_red_get_password();
|
$password = post_to_red_get_password();
|
||||||
@ -122,7 +119,7 @@ function post_to_red_delete_post($post_id) {
|
|||||||
$post = get_post($post_id);
|
$post = get_post($post_id);
|
||||||
|
|
||||||
// if meta has been set
|
// if meta has been set
|
||||||
if (get_post_meta($post_id, "post_to_red", true) == 1) {
|
if (get_post_meta($post_id, "post_to_red", true) == '1') {
|
||||||
|
|
||||||
$user_name = post_to_red_get_acct_name();
|
$user_name = post_to_red_get_acct_name();
|
||||||
$password = post_to_red_get_password();
|
$password = post_to_red_get_password();
|
||||||
@ -221,10 +218,8 @@ function post_to_red_post_field_data($post_id) {
|
|||||||
|
|
||||||
// now store data in custom fields based on checkboxes selected
|
// now store data in custom fields based on checkboxes selected
|
||||||
if (isset($_POST['post_to_red'])) {
|
if (isset($_POST['post_to_red'])) {
|
||||||
update_post_meta($post_id, 'post_to_red', 1);
|
update_post_meta($post_id, 'post_to_red', '1');
|
||||||
} else {
|
}
|
||||||
update_post_meta($post_id, 'post_to_red', 0);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function post_to_red_display_admin_page() {
|
function post_to_red_display_admin_page() {
|
||||||
|
Reference in New Issue
Block a user