get_results("SELECT id, type FROM". RC_CWP_TABLE_WRITE_PANELS ." WHERE id='".$_GET['custom-write-panel-id']."'"); echo "type ."\" />"; } else{ if($post->post_type == 'page') { echo ""; } else { echo ""; } } } function cwp_add_pages_identifiers(){ global $post; global $wpdb; $key = wp_create_nonce('rc-custom-write-panel'); $id = ""; $result = $wpdb->get_results( " SELECT meta_value FROM $wpdb->postmeta WHERE post_id = '$post->ID' and meta_key = '_rc_cwp_write_panel_id'", ARRAY_A ); if (count($result) > 0) $id = $result[0]['meta_value']; echo << EOF; } add_action('edit_page_form','cwp_add_pages_identifiers'); add_action('edit_form_advanced','cwp_add_type_identifier'); ?>