Walker_Comment::start_lvl()
Starts the list before the elements are added.
Method of the class: Walker_Comment{}
No Hooks.
Return
null
. Ничего (null).
Usage
$Walker_Comment = new Walker_Comment(); $Walker_Comment->start_lvl( $output, $depth, $args );
- $output(string) (required) (passed by reference — &)
- Used to append additional content (passed by reference).
- $depth(int)
- Depth of the current comment.
- $args(array)
- Uses 'style' argument for type of HTML list.
Default: empty array
Notes
- See: Walker::start_lvl()
- Global. Int. $comment_depth
Changelog
Since 2.7.0 | Introduced. |
Walker_Comment::start_lvl() Walker Comment::start lvl code WP 6.3
public function start_lvl( &$output, $depth = 0, $args = array() ) { $GLOBALS['comment_depth'] = $depth + 1; switch ( $args['style'] ) { case 'div': break; case 'ol': $output .= '<ol class="children">' . "\n"; break; case 'ul': default: $output .= '<ul class="children">' . "\n"; break; } }