wp_list_bookmarks example

<?php                 wp_list_categories(
                    array(
                        'show_count' => 1,
                        'title_li'   => '<h2>' . __( 'Categories' ) . '</h2>',
                    )
                );
                ?> </ul> <ul> <?php if ( is_home() || is_page() ) { /* If this is the frontpage */ ?> <?php wp_list_bookmarks(); ?> <li><h2><?php _e( 'Meta' ); ?></h2> <ul> <?php wp_register(); ?> <li><?php wp_loginout(); ?></li> <?php wp_meta(); ?> </ul> </li> <?php } ?> <?php endif; /* ! dynamic_sidebar() */ ?>
/** * Filters the arguments for the Links widget. * * @since 2.6.0 * @since 4.4.0 Added the `$instance` parameter. * * @see wp_list_bookmarks() * * @param array $widget_links_args An array of arguments to retrieve the links list. * @param array $instance The settings for the particular instance of the widget. */
        wp_list_bookmarks( apply_filters( 'widget_links_args', $widget_links_args$instance ) );
    }

    /** * Handles updating settings for the current Links widget instance. * * @since 2.8.0 * * @param array $new_instance New settings for this instance as input by the user via * WP_Widget::form(). * @param array $old_instance Old settings for this instance. * @return array Updated settings to save. */
'before' => '',
        'categorize' => 0,
        'category_after' => '',
        'category_before' => '',
        'category_name' => $category,
        'show_description' => 1,
        'title_li' => '',
    );

    $parsed_args = wp_parse_args( $args$defaults );

    return wp_list_bookmarks($parsed_args);
}

/** * Gets an array of link objects associated with category $cat_name. * * $links = get_linkobjectsbyname( 'fred' ); * foreach ( $links as $link ) { * echo '<li>' . $link->link_name . '</li>'; * } * * @since 1.0.1 * @deprecated 2.1.0 Use get_bookmarks() * @see get_bookmarks() * * @param string $cat_name Optional. The category name to use. If no match is found, uses all. * Default 'noname'. * @param string $orderby Optional. The order to output the links. E.g. 'id', 'name', 'url', * 'description', 'rating', or 'owner'. Default 'name'. * If you start the name with an underscore, the order will be reversed. * Specifying 'rand' as the order will return links in a random order. * @param int $limit Optional. Limit to X entries. If not specified, all entries are shown. * Default -1. * @return array */
Home | Imprint | This part of the site doesn't use cookies.