controls
6 months ago
helpers
6 months ago
pa-display-conditions
6 months ago
templates
6 months ago
acf-helper.php
6 months ago
addons-cross-cp.php
6 months ago
addons-integration.php
6 months ago
assets-manager.php
6 months ago
class-pa-core.php
6 months ago
cm-pointer.php
6 months ago
helper-functions.php
6 months ago
live-editor-modal.php
6 months ago
module-base.php
6 months ago
pa-nav-menu-walker.php
6 months ago
papro-promotion.php
6 months ago
premium-template-tags.php
6 months ago
pa-nav-menu-walker.php
517 lines
| 1 | <?php |
| 2 | /** |
| 3 | * PA Nav Menu Walker. |
| 4 | */ |
| 5 | |
| 6 | namespace PremiumAddons\Includes; |
| 7 | |
| 8 | // PA classes. |
| 9 | use PremiumAddons\Includes\Helper_Functions; |
| 10 | |
| 11 | if ( ! defined( 'ABSPATH' ) ) { |
| 12 | exit; // Exit if accessed directly. |
| 13 | } |
| 14 | |
| 15 | /** |
| 16 | * Class Pa_Nav_Menu_Walker. |
| 17 | */ |
| 18 | class Pa_Nav_Menu_Walker extends \Walker_Nav_Menu { |
| 19 | |
| 20 | /** |
| 21 | * Menu Settings. |
| 22 | * |
| 23 | * @var settings |
| 24 | */ |
| 25 | private $settings = null; |
| 26 | |
| 27 | /** |
| 28 | * Is mobile menu flag. |
| 29 | * |
| 30 | * @var is_mobile_menu |
| 31 | */ |
| 32 | private $is_mobile_menu = null; |
| 33 | |
| 34 | |
| 35 | /** |
| 36 | * Class Constructor. |
| 37 | * |
| 38 | * @param array $widget_settings widget settings. |
| 39 | * @param bool $is_mobile_menu is toggle menu flag. |
| 40 | */ |
| 41 | public function __construct( $widget_settings, $is_mobile_menu = false ) { |
| 42 | |
| 43 | $this->settings = $widget_settings; |
| 44 | |
| 45 | $this->is_mobile_menu = $is_mobile_menu; |
| 46 | } |
| 47 | |
| 48 | /** |
| 49 | * Get Item Postmeta data. |
| 50 | * |
| 51 | * @since 4.9.4 |
| 52 | * @access public |
| 53 | * |
| 54 | * @param int|string $item_id menu item id. |
| 55 | * |
| 56 | * @return object |
| 57 | */ |
| 58 | public function get_item_postmeta( $item_id ) { |
| 59 | |
| 60 | $defauls = array( |
| 61 | 'item_id' => '', |
| 62 | 'item_icon' => '', |
| 63 | 'item_badge' => '', |
| 64 | 'item_depth' => '', |
| 65 | 'item_badge_bg' => '', |
| 66 | 'item_icon_type' => '', |
| 67 | 'item_lottie_url' => '', |
| 68 | 'item_icon_color' => '', |
| 69 | 'item_badge_color' => '', |
| 70 | 'mega_content_pos' => '', |
| 71 | 'mega_content_width' => '', |
| 72 | 'mega_content_enabled' => '', |
| 73 | 'full_width_mega_content' => '', |
| 74 | ); |
| 75 | |
| 76 | $item_meta = array_merge( $defauls, (array) json_decode( get_post_meta( $item_id, 'pa_megamenu_item_meta', true ) ) ); |
| 77 | |
| 78 | return (object) $item_meta; |
| 79 | } |
| 80 | |
| 81 | /** |
| 82 | * Get Mega Content ID. |
| 83 | * Retrieves mega content id from postmeta table. |
| 84 | * |
| 85 | * @access public |
| 86 | * @since 4.9.4 |
| 87 | * |
| 88 | * @param string $item_id menu item id. |
| 89 | * |
| 90 | * @return string |
| 91 | */ |
| 92 | public function get_mega_content_id( $item_id ) { |
| 93 | return get_post_meta( $item_id, 'pa_mega_content_temp', true ); |
| 94 | } |
| 95 | |
| 96 | /** |
| 97 | * Get default submenu icon. |
| 98 | * |
| 99 | * @access public |
| 100 | * @since 4.9.18 |
| 101 | * |
| 102 | * @param string $layout main menu layout. |
| 103 | * |
| 104 | * @return string |
| 105 | */ |
| 106 | public function get_default_submenu_icon() { |
| 107 | |
| 108 | // toggle menu icon. |
| 109 | if ( $this->is_mobile_menu ) { |
| 110 | return 'fas fa-angle-down'; |
| 111 | } |
| 112 | |
| 113 | $icon = 'fas fa-angle-right'; |
| 114 | $layout = $this->settings['pa_nav_menu_layout']; |
| 115 | |
| 116 | switch ( $layout ) { |
| 117 | case 'hor': |
| 118 | if ( is_rtl() ) { |
| 119 | $icon = 'fas fa-angle-left'; |
| 120 | } |
| 121 | break; |
| 122 | |
| 123 | case 'slide': |
| 124 | case 'dropdown': |
| 125 | $icon = 'fas fa-angle-down'; |
| 126 | break; |
| 127 | |
| 128 | case 'ver': |
| 129 | $icon = 'fas fa-angle-' . $this->settings['pa_nav_ver_submenu']; |
| 130 | break; |
| 131 | } |
| 132 | |
| 133 | return $icon; |
| 134 | } |
| 135 | |
| 136 | /** |
| 137 | * Starts the list before the elements are added. |
| 138 | * |
| 139 | * @since 3.0.0 |
| 140 | * |
| 141 | * @see Walker::start_lvl() |
| 142 | * |
| 143 | * @param string $output Used to append additional content (passed by reference). |
| 144 | * @param int $depth Depth of menu item. Used for padding. |
| 145 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 146 | */ |
| 147 | public function start_lvl( &$output, $depth = 0, $args = null ) { |
| 148 | |
| 149 | $settings = $this->settings; |
| 150 | |
| 151 | if ( isset( $args->item_spacing ) && 'discard' === $args->item_spacing ) { |
| 152 | $t = ''; |
| 153 | $n = ''; |
| 154 | } else { |
| 155 | $t = "\t"; |
| 156 | $n = "\n"; |
| 157 | } |
| 158 | |
| 159 | $indent = str_repeat( $t, $depth ); |
| 160 | |
| 161 | $classes = array( 'premium-sub-menu', 'premium-lq__' . $settings['submenu_lq_effect'] ); |
| 162 | |
| 163 | /** |
| 164 | * Filters the CSS class(es) applied to a menu list element. |
| 165 | * |
| 166 | * @since 4.8.0 |
| 167 | * |
| 168 | * @param string[] $classes Array of the CSS classes that are applied to the menu `<ul>` element. |
| 169 | * @param stdClass $args An object of `wp_nav_menu()` arguments. |
| 170 | * @param int $depth Depth of menu item. Used for padding. |
| 171 | */ |
| 172 | $class_names = implode( ' ', apply_filters( 'nav_menu_submenu_css_class', $classes, $args, $depth ) ); |
| 173 | $class_names = $class_names ? ' class="' . esc_attr( $class_names ) . '"' : ''; |
| 174 | |
| 175 | $output .= "{$n}{$indent}<ul$class_names>{$n}"; |
| 176 | } |
| 177 | |
| 178 | /** |
| 179 | * Ends the list of after the elements are added. |
| 180 | * |
| 181 | * @since 3.0.0 |
| 182 | * |
| 183 | * @see Walker::end_lvl() |
| 184 | * |
| 185 | * @param string $output Used to append additional content (passed by reference). |
| 186 | * @param int $depth Depth of menu item. Used for padding. |
| 187 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 188 | */ |
| 189 | public function end_lvl( &$output, $depth = 0, $args = null ) { |
| 190 | if ( isset( $args->item_spacing ) && 'discard' === $args->item_spacing ) { |
| 191 | $t = ''; |
| 192 | $n = ''; |
| 193 | } else { |
| 194 | $t = "\t"; |
| 195 | $n = "\n"; |
| 196 | } |
| 197 | $indent = str_repeat( $t, $depth ); |
| 198 | $output .= "$indent</ul>{$n}"; |
| 199 | } |
| 200 | |
| 201 | /** |
| 202 | * Starts the element output. |
| 203 | * |
| 204 | * @since 3.0.0 |
| 205 | * @since 4.4.0 The {@see 'nav_menu_item_args'} filter was added. |
| 206 | * @since 5.9.0 Renamed `$item` to `$data_object` and `$id` to `$current_object_id` |
| 207 | * to match parent class for PHP 8 named parameter support. |
| 208 | * |
| 209 | * @see Walker::start_el() |
| 210 | * |
| 211 | * @param string $output Used to append additional content (passed by reference). |
| 212 | * @param WP_Post $data_object Menu item data object. |
| 213 | * @param int $depth Depth of menu item. Used for padding. |
| 214 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 215 | * @param int $current_object_id Optional. ID of the current menu item. Default 0. |
| 216 | */ |
| 217 | public function start_el( &$output, $data_object, $depth = 0, $args = array(), $current_object_id = 0 ) { |
| 218 | |
| 219 | $settings = $this->settings; |
| 220 | |
| 221 | // Restores the more descriptive, specific name for use within this method. |
| 222 | $menu_item = $data_object; |
| 223 | |
| 224 | if ( is_null( $menu_item ) ) { |
| 225 | return; |
| 226 | } |
| 227 | |
| 228 | $item_meta = $this->get_item_postmeta( $menu_item->ID ); |
| 229 | |
| 230 | if ( isset( $args->item_spacing ) && 'discard' === $args->item_spacing ) { |
| 231 | $t = ''; |
| 232 | $n = ''; |
| 233 | } else { |
| 234 | $t = "\t"; |
| 235 | $n = "\n"; |
| 236 | } |
| 237 | |
| 238 | $indent = ( $depth ) ? str_repeat( $t, $depth ) : ''; |
| 239 | |
| 240 | $classes = empty( $menu_item->classes ) ? array() : (array) $menu_item->classes; // has default classes. |
| 241 | |
| 242 | $classes[] = 'premium-nav-menu-item'; // add our own class too. |
| 243 | |
| 244 | if ( 0 < $depth ) { |
| 245 | $classes[] = 'premium-sub-menu-item'; |
| 246 | } |
| 247 | |
| 248 | if ( 'true' == $item_meta->mega_content_enabled ) { |
| 249 | $classes[] = 'premium-mega-nav-item menu-item-has-children'; |
| 250 | |
| 251 | if ( 'default' === $item_meta->mega_content_pos ) { |
| 252 | $classes[] = 'premium-mega-item-static'; |
| 253 | } |
| 254 | } |
| 255 | |
| 256 | /** handling active anchor links which redirects to an id in a page. |
| 257 | * make sure we exclude URL with the #/ as it's not a valid ID selector. |
| 258 | */ |
| 259 | $is_anchor = false !== strpos( $menu_item->url, '#' ) && false === strpos( $menu_item->url, '#/' ); |
| 260 | |
| 261 | // we can later add other classes here based on the user settings. |
| 262 | if ( ! $is_anchor && in_array( 'current-menu-item', $classes, true ) ) { |
| 263 | $classes[] = 'premium-active-item'; |
| 264 | } |
| 265 | |
| 266 | if ( $is_anchor ) { // the active class will be added via js. |
| 267 | $classes[] = 'premium-item-anchor'; |
| 268 | } |
| 269 | |
| 270 | // Add badge marker. |
| 271 | if ( ! empty( $item_meta->item_badge ) ) { |
| 272 | $classes[] = 'has-pa-badge'; |
| 273 | |
| 274 | // check for sub item badge effects. |
| 275 | $badge_effect = $settings['sub_badge_hv_effects']; |
| 276 | |
| 277 | if ( 0 < $depth && '' !== $badge_effect ) { |
| 278 | $classes[] = 'premium-badge-' . $badge_effect; |
| 279 | } |
| 280 | } |
| 281 | |
| 282 | /** |
| 283 | * Filters the arguments for a single nav menu item. |
| 284 | * |
| 285 | * @since 4.4.0 |
| 286 | * |
| 287 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 288 | * @param WP_Post $menu_item Menu item data object. |
| 289 | * @param int $depth Depth of menu item. Used for padding. |
| 290 | */ |
| 291 | $args = apply_filters( 'nav_menu_item_args', $args, $menu_item, $depth ); // default fitler. |
| 292 | |
| 293 | /** |
| 294 | * Filters the CSS classes applied to a menu item's list item element. |
| 295 | * |
| 296 | * @since 3.0.0 |
| 297 | * @since 4.1.0 The `$depth` parameter was added. |
| 298 | * |
| 299 | * @param string[] $classes Array of the CSS classes that are applied to the menu item's `<li>` element. |
| 300 | * @param WP_Post $menu_item The current menu item object. |
| 301 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 302 | * @param int $depth Depth of menu item. Used for padding. |
| 303 | */ |
| 304 | $class_names = implode( ' ', apply_filters( 'nav_menu_css_class', array_filter( $classes ), $menu_item, $args, $depth ) ); |
| 305 | $class_names = $class_names ? ' class="' . esc_attr( $class_names ) . '"' : ''; |
| 306 | |
| 307 | /** |
| 308 | * Filters the ID applied to a menu item's list item element. |
| 309 | * |
| 310 | * @since 3.0.1 |
| 311 | * @since 4.1.0 The `$depth` parameter was added. |
| 312 | * |
| 313 | * @param string $menu_id The ID that is applied to the menu item's `<li>` element. |
| 314 | * @param WP_Post $menu_item The current menu item. |
| 315 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 316 | * @param int $depth Depth of menu item. Used for padding. |
| 317 | */ |
| 318 | $id = apply_filters( 'nav_menu_item_id', 'premium-nav-menu-item-' . $menu_item->ID, $menu_item, $args, $depth ); // change the default id. |
| 319 | $id = $id ? ' id="' . esc_attr( $id ) . '"' : ''; |
| 320 | |
| 321 | $full_width = 'true' == $item_meta->full_width_mega_content ? ' data-full-width="true"' : ''; |
| 322 | |
| 323 | $output .= $indent . '<li' . $id . $class_names . $full_width . '>'; |
| 324 | // link attributes. |
| 325 | $atts = array(); |
| 326 | $atts['title'] = ! empty( $menu_item->attr_title ) ? $menu_item->attr_title : ''; |
| 327 | $atts['target'] = ! empty( $menu_item->target ) ? $menu_item->target : ''; |
| 328 | |
| 329 | if ( '_blank' === $menu_item->target && empty( $menu_item->xfn ) ) { |
| 330 | |
| 331 | $atts['rel'] = 'noopener'; |
| 332 | } else { |
| 333 | |
| 334 | $atts['rel'] = $menu_item->xfn; |
| 335 | } |
| 336 | |
| 337 | $atts['href'] = ! empty( $menu_item->url ) ? $menu_item->url : ''; |
| 338 | $atts['aria-current'] = $menu_item->current ? 'page' : ''; |
| 339 | |
| 340 | /** |
| 341 | * Page-Transition Experiment Fix. |
| 342 | * add elementor's custom attribute to Toggle menu links |
| 343 | * && if the element has sub|mega menu. |
| 344 | */ |
| 345 | $is_parent = in_array( 'menu-item-has-children', $classes, true ) || 'true' == $item_meta->mega_content_enabled; |
| 346 | $is_toggle = in_array( $settings['pa_nav_menu_layout'], array( 'dropdown', 'slide' ), true ) || wp_is_mobile(); |
| 347 | |
| 348 | if ( $is_toggle && $is_parent ) { |
| 349 | $atts['data-e-disable-page-transition'] = 'true'; |
| 350 | } |
| 351 | |
| 352 | /** |
| 353 | * Filters the HTML attributes applied to a menu item's anchor element. |
| 354 | * |
| 355 | * @since 3.6.0 |
| 356 | * @since 4.1.0 The `$depth` parameter was added. |
| 357 | * |
| 358 | * @param array $atts { |
| 359 | * The HTML attributes applied to the menu item's `<a>` element, empty strings are ignored. |
| 360 | * |
| 361 | * @type string $title Title attribute. |
| 362 | * @type string $target Target attribute. |
| 363 | * @type string $rel The rel attribute. |
| 364 | * @type string $href The href attribute. |
| 365 | * @type string $aria-current The aria-current attribute. |
| 366 | * } |
| 367 | * @param WP_Post $menu_item The current menu item object. |
| 368 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 369 | * @param int $depth Depth of menu item. Used for padding. |
| 370 | */ |
| 371 | $atts = apply_filters( 'nav_menu_link_attributes', $atts, $menu_item, $args, $depth ); |
| 372 | |
| 373 | // add our own class. |
| 374 | if ( empty( $atts['class'] ) ) { |
| 375 | $atts['class'] = 'premium-menu-link'; |
| 376 | } else { |
| 377 | $atts['class'] .= ' premium-menu-link'; |
| 378 | } |
| 379 | |
| 380 | if ( 0 == $depth ) { |
| 381 | |
| 382 | $atts['class'] .= ' premium-menu-link-parent'; |
| 383 | $atts['class'] .= ' premium-lq__' . $settings['item_lq_effect']; |
| 384 | } |
| 385 | |
| 386 | $dropdown_icon = ''; |
| 387 | |
| 388 | $dropdown_icon_class = ''; |
| 389 | $item_icon = ''; |
| 390 | $item_badge = ''; |
| 391 | $icon_class = 0 < $depth ? ' premium-sub-item-icon' : ' premium-item-icon'; |
| 392 | $badge_class = 0 < $depth ? 'premium-sub-item-badge' : 'premium-item-badge'; |
| 393 | |
| 394 | if ( in_array( 'menu-item-has-children', $classes, true ) || 'true' == $item_meta->mega_content_enabled ) { |
| 395 | |
| 396 | // $dropdown_icon_class = 0 === $depth ? $settings['submenu_icon']['value'] : $this->get_default_submenu_icon(); |
| 397 | |
| 398 | // submenu_item_icon. |
| 399 | if ( 0 === $depth ) { |
| 400 | $dropdown_icon_class = $settings['submenu_icon']['value']; |
| 401 | } else { |
| 402 | $dropdown_icon_class = ! empty( $settings['submenu_item_icon']['value'] ) ? $settings['submenu_item_icon']['value'] : $this->get_default_submenu_icon(); |
| 403 | } |
| 404 | |
| 405 | if ( ! empty( $dropdown_icon_class ) ) { |
| 406 | |
| 407 | $dropdown_icon_class .= ' premium-dropdown-icon'; |
| 408 | $dropdown_icon = sprintf( '<i class="%1$s"></i>', esc_attr( $dropdown_icon_class ) ); |
| 409 | |
| 410 | } |
| 411 | } |
| 412 | |
| 413 | // add item icon. |
| 414 | if ( 'icon' === $item_meta->item_icon_type && ! empty( $item_meta->item_icon ) ) { |
| 415 | $item_icon = sprintf( '<i class="%1$s" style="color:%2$s"></i>', esc_attr( $item_meta->item_icon . $icon_class ), esc_attr( $item_meta->item_icon_color ) ); |
| 416 | } elseif ( 'lottie' === $item_meta->item_icon_type && ! empty( $item_meta->item_lottie_url ) ) { |
| 417 | $item_icon = sprintf( '<div class="%1$s" data-lottie-url="%2$s" data-lottie-loop="true"></div>', esc_attr( $icon_class ) . ' premium-lottie-animation', esc_url( $item_meta->item_lottie_url ) ); |
| 418 | } |
| 419 | |
| 420 | // add item badge. |
| 421 | if ( ! empty( $item_meta->item_badge ) ) { |
| 422 | $item_badge = sprintf( '<span class="%1$s" style="color:%2$s; background-color:%3$s;">%4$s</span>', esc_attr( $badge_class ), esc_attr( $item_meta->item_badge_color ), esc_attr( $item_meta->item_badge_bg ), esc_attr( $item_meta->item_badge ) ); |
| 423 | } |
| 424 | |
| 425 | if ( 0 < $depth ) { |
| 426 | $atts['class'] .= ' premium-sub-menu-link'; |
| 427 | } |
| 428 | |
| 429 | $attributes = ''; |
| 430 | foreach ( $atts as $attr => $value ) { |
| 431 | if ( is_scalar( $value ) && '' !== $value && false !== $value ) { |
| 432 | $value = ( 'href' === $attr ) ? esc_url( $value ) : esc_attr( $value ); |
| 433 | $attributes .= ' ' . $attr . '="' . $value . '"'; |
| 434 | } |
| 435 | } |
| 436 | |
| 437 | /** This filter is documented in wp-includes/post-template.php */ |
| 438 | $title = apply_filters( 'the_title', $menu_item->title, $menu_item->ID ); |
| 439 | |
| 440 | /** |
| 441 | * Filters a menu item's title. |
| 442 | * |
| 443 | * @since 4.4.0 |
| 444 | * |
| 445 | * @param string $title The menu item's title. |
| 446 | * @param WP_Post $menu_item The current menu item object. |
| 447 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 448 | * @param int $depth Depth of menu item. Used for padding. |
| 449 | */ |
| 450 | $title = apply_filters( 'nav_menu_item_title', $title, $menu_item, $args, $depth ); |
| 451 | |
| 452 | $item_output = $args->before; |
| 453 | $item_output .= '<a' . $attributes . '>'; |
| 454 | $item_output .= $args->link_before . $item_icon . $title . $dropdown_icon . $item_badge . $args->link_after; |
| 455 | $item_output .= '</a>'; |
| 456 | $item_output .= $args->after; |
| 457 | |
| 458 | /** |
| 459 | * Filters a menu item's starting output. |
| 460 | * |
| 461 | * The menu item's starting output only includes `$args->before`, the opening `<a>`, |
| 462 | * the menu item's title, the closing `</a>`, and `$args->after`. Currently, there is |
| 463 | * no filter for modifying the opening and closing `<li>` for a menu item. |
| 464 | * |
| 465 | * @since 3.0.0 |
| 466 | * |
| 467 | * @param string $item_output The menu item's starting HTML output. |
| 468 | * @param WP_Post $menu_item Menu item data object. |
| 469 | * @param int $depth Depth of menu item. Used for padding. |
| 470 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 471 | */ |
| 472 | $output .= apply_filters( 'walker_nav_menu_start_el', $item_output, $menu_item, $depth, $args ); |
| 473 | } |
| 474 | |
| 475 | /** |
| 476 | * Ends the element output, if needed. |
| 477 | * |
| 478 | * @since 3.0.0 |
| 479 | * @since 5.9.0 Renamed `$item` to `$data_object` to match parent class for PHP 8 named parameter support. |
| 480 | * |
| 481 | * @see Walker::end_el() |
| 482 | * |
| 483 | * @param string $output Used to append additional content (passed by reference). |
| 484 | * @param WP_Post $data_object Menu item data object. Not used. |
| 485 | * @param int $depth Depth of page. Not Used. |
| 486 | * @param stdClass $args An object of wp_nav_menu() arguments. |
| 487 | */ |
| 488 | public function end_el( &$output, $data_object, $depth = 0, $args = null ) { |
| 489 | |
| 490 | /** |
| 491 | * Add mega content to main nav menu items only. |
| 492 | */ |
| 493 | if ( 0 === $depth ) { |
| 494 | |
| 495 | $item_meta = $this->get_item_postmeta( $data_object->ID ); |
| 496 | |
| 497 | if ( 'true' == $item_meta->mega_content_enabled && class_exists( 'Elementor\Plugin' ) ) { |
| 498 | |
| 499 | $temp_id = $this->get_mega_content_id( $data_object->ID ); |
| 500 | $content = Helper_Functions::render_elementor_template( $temp_id, true ); |
| 501 | $style = 'width:' . $item_meta->mega_content_width; |
| 502 | $output .= sprintf( '<div id="premium-mega-content-%1$s" class="premium-mega-content-container" style="%2$s">%3$s</div>', $data_object->ID, $style, $content ); |
| 503 | } |
| 504 | } |
| 505 | |
| 506 | if ( isset( $args->item_spacing ) && 'discard' === $args->item_spacing ) { |
| 507 | $t = ''; |
| 508 | $n = ''; |
| 509 | } else { |
| 510 | $t = "\t"; |
| 511 | $n = "\n"; |
| 512 | } |
| 513 | |
| 514 | $output .= "</li>{$n}"; |
| 515 | } |
| 516 | } |
| 517 |