" => // // "" => // // [nnhw-zmcg] => a-1448527327 (approved) // // [9khc-zwmv] => r-1448527327 (rejected) // // ... // // ) // // ------------------------------------------------------------------------- //\greatKiwi_byFernTec_adSwapper_local_v0x1x211_testDebug\pr( // $manually_approved_available_ads , // '$manually_approved_available_ads' // ) ; // ========================================================================= // Update the current value... // ========================================================================= $question_value_updated = FALSE ; // ------------------------------------------------------------------------- if ( array_key_exists( $ad_sid , $manually_approved_available_ads ) ) { // --------------------------------------------------------------------- $parts = explode( '-' , $manually_approved_available_ads[ $ad_sid ] ) ; // --------------------------------------------------------------------- if ( count( $parts ) !== 2 || ! in_array( $parts[0] , array( 'a' , 'r' ) , TRUE ) || trim( $parts[1] ) === '' || ! ctype_digit( $parts[1] ) ) { $ln = __LINE__ - 6 ; return <<prepare before the INSERT statement but not the option value, // this value should always be properly sanitized. // // This function may be used in place of add_option, although it is not as // flexible. update_option will check to see if the option already exists. // If it does not, it will be added with add_option('option_name', // 'option_value'). Unless you need to specify the optional arguments of // add_option(), update_option() is a useful catch-all for both adding and // updating options. // // $option // (string) (required) Name of the option to update. Must not // exceed 64 characters. A list of valid default options to update // can be found at the Option Reference. // Default: None // // $new_value // (mixed) (required) The NEW value for this option name. This // value can be an integer, string, array, or object. // Default: None // // $autoload // (mixed) (optional) Whether to load the option when WordPress // starts up. For existing options `$autoload` can only be updated // using `update_option()` if `$value` is also changed. Accepts // 'yes' or true to enable, 'no' or false to disable. For // non-existent options, the default value is 'yes'. // Default: null // // RETURN VALUE // (boolean) True if option value has changed, false if not or if // update failed. // ------------------------------------------------------------------------- $result = update_option( $option_name , $manually_approved_available_ads ) ; // --------------------------------------------------------------------- if ( $result !== TRUE ) { $ln = __LINE__ - 2 ; return <<