Changeset 3165845
- Timestamp:
- 10/09/2024 02:12:09 PM (18 months ago)
- Location:
- hellodialog/trunk
- Files:
-
- 2 edited
-
index.php (modified) (4 diffs)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
hellodialog/trunk/index.php
r2984270 r3165845 4 4 * Plugin URI: https://www.hellodialog.com 5 5 * Description: This plugin connects Wordpress to the Hellodialog API. 6 * Version: 1.7.1 16 * Version: 1.7.12 7 7 * Author: Webreact 8 8 * Author URI: https://www.webreact.nl … … 369 369 } 370 370 371 /** 372 * Cast variable to array. 373 * 374 * @param $variable 375 * @return array 376 */ 377 function hd_to_array($variable) { 378 return (array) $variable; 379 } 380 371 381 /** 372 382 * Save the metadate when the custom post type is mutated. … … 404 414 */ 405 415 if( isset ( $_POST['custom-meta-box2'] ) ) { 406 $custom2 = $_POST['custom-meta-box2'];407 $old_meta2 = get_post_meta($post->ID, '_custom-meta-box2', true);416 $custom2 = hd_to_array($_POST['custom-meta-box2']); 417 $old_meta2 = hd_to_array(get_post_meta($post->ID, '_custom-meta-box2', true)); 408 418 409 419 $custom2 = array_map( 'sanitize_text_field', $custom2 ); … … 429 439 if( isset ( $_POST['custom-meta-box'] ) ) { 430 440 // Get input & sanitize after 431 $custom = $_POST['custom-meta-box'];432 $old_meta = get_post_meta($post->ID, '_custom-meta-box', true);441 $custom = hd_to_array($_POST['custom-meta-box']); 442 $old_meta = hd_to_array(get_post_meta($post->ID, '_custom-meta-box', true)); 433 443 434 444 // Sanitize input -
hellodialog/trunk/readme.txt
r2984270 r3165845 5 5 Requires at least: 4.8 6 6 Tested up to: 6.4 7 Stable tag: 1.7.1 17 Stable tag: 1.7.12 8 8 License: GPLv2 or later 9 9 License URI: https://www.gnu.org/licenses/gpl-2.0.html … … 48 48 49 49 == Changelog == 50 = 1.7.12 = 51 * Fixed type error on array_map() argument two. 52 53 = 1.7.11 = 54 * WordPress 6.4 compatibility. 55 50 56 = 1.7.10 = 51 57 * Added a fix where usage of the shortcode would throw warnings.
Note: See TracChangeset
for help on using the changeset viewer.