Why user is added back in database after deletion?

I solved this by doing something link $hook = add_menu_page(‘My Plugin Settings’,’My Plugin Settings’,’manage_options’,’my_plugin_settings’,’display_plugin_options’); add_action(‘load-‘.$hook,’do_on_my_plugin_settings_save’); function do_on_my_plugin_settings_save() { if(isset($_GET[‘settings-updated’]) && $_GET[‘settings-updated’]) { //plugin settings have been saved. Here goes your code } }

Custom MySQL query to pull out Advanced Custom Fields?

The code is fine, I can’t see any need to modify the query – I think you’re missing the third argument in your get_post_meta call: $postACF_sc = get_post_meta($postId, ‘sc_link’, true /* $single */); You might also want to add this snippet just before the foreach to save multiple database queries: update_postmeta_cache( wp_list_pluck( $posts, ‘posts_id’ ) … Read more

WordPress Plugin: OSCommerce images not displaying in front end

Thanks for the reply. The oscommer_importer.php file already tried to retrieve fields from products table. Here I have attached it. ` <?php /* Plugin Name: OSCommerce Product Display Plugin URI: http://localhost:8383 Description: Plugin for displaying products from an OSCommerce shopping cart database Author: Priya Mohan Version: 1.0 */ function oscimp_admin() { include(‘oscommerce_import_admin.php’);?> <?php } function … Read more

wordpress plugin require_once file – can’t user wordpress functions

I’m not sure if you’re trying to use WordPress functions outside of the actual WordPress application, but to accomplish this you simply need to do: require( ‘path-to-wordpress/wp-load.php’ ); at the top of your file, if the path to the WordPress application is in fact $_SERVER[‘DOCUMENT_ROOT’] then you would do require ( $_SERVER[‘DOCUMENT_ROOT’] . ‘/wp-load.php’ );