From 2ee981184f46e77203150349ce3c371fbf5d6f06 Mon Sep 17 00:00:00 2001 From: sadtross Date: Thu, 18 Jan 2024 10:02:14 +0100 Subject: [PATCH] custom edit page: Fix expected string error --- includes/custom-edit-page.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/includes/custom-edit-page.php b/includes/custom-edit-page.php index a3a6e0c6..b75e12a0 100644 --- a/includes/custom-edit-page.php +++ b/includes/custom-edit-page.php @@ -60,6 +60,14 @@ function contact_custom_box_html( $post ) { $formatted_value = apply_filters( 'qterest_format_value', $value ); } + if ( is_array( $formatted_value ) ) { + $formatted_value = implode( ', ', $formatted_value ); + } + + if ( is_array( $value ) ) { + $value = implode( ', ', $value ); + } + $is_link = substr( $value, 0, 4 ) == 'http'; echo '' . $formatted_key . '' . ( $is_link ? "$formatted_value" : $formatted_value ) . '';