From 2683192dd3cda29a70d1582aa8a0a3f790ebbeb9 Mon Sep 17 00:00:00 2001 From: syshut Date: Sun, 12 Dec 2021 11:50:26 +0800 Subject: [PATCH] =?UTF-8?q?=E9=81=BF=E5=85=8D=20php=208.0=20=E5=87=BA?= =?UTF-8?q?=E8=AD=A6=E5=91=8A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- inc/core.de.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/inc/core.de.php b/inc/core.de.php index 0e2fa10..3e26c80 100755 --- a/inc/core.de.php +++ b/inc/core.de.php @@ -32,12 +32,12 @@ function start_el(&$output, $item, $depth = 0, $args = array(), $id = 0) if ($depth != 0) $description = ""; - $item_output = $args->before; + $item_output = (isset ($args->before)) ? $args->before : ''; $item_output .= ''; - $item_output .= $args->link_before . apply_filters('the_title', $item->title, $item->ID); - $item_output .= $description . $args->link_after; + if (isset ($args->link_before)) $item_output .= $args->link_before . apply_filters('the_title', $item->title, $item->ID); + if (isset ($args->link_after)) $item_output .= $description . $args->link_after; $item_output .= ''; - $item_output .= $args->after; + if (isset ($args->after)) $item_output .= $args->after; $output .= apply_filters('walker_nav_menu_start_el', $item_output, $item, $depth, $args); }