How to delete orphan userdata from array in wp-options

If what posted is all the code you are using, you unsetting the value from the retreved array using unset, but then you don’t save again the array on database: add_action( ‘delete_user’, ‘forum_remove_deleted_user’ ); function forum_remove_deleted_user($user_id) { $user_obj = get_userdata($user_id); $subscbr_email = $user_obj->user_email; if( ! empty( $subscbr_email ) ) { $list = (array) get_option(‘mf_forum_subscribers_1’); if( … Read more

get unserialized array without using get_option()

You can use the following two inbuilt functions to do this. switch_to_blog get_option You can use both in the following way to make a function out of it which would give you the option. Put the below in the functions.php file function wpse_get_options( $blog_id = 1 ){ switch_to_blog( $blog_id ); $get_option = get_option( $option ); … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)