Embed the most popular bookmarks into your web pages. Your web application can use this resource to enable users to see and navigate to the most popular bookmarks embedded on your web page.

Embed the most popular bookmarks into your web pages. Your web application can use this resource to enable users to see and navigate to the most popular bookmarks embedded on your web page.

This lists the bookmarks that multiple users have bookmarked recently. It captures the bookmarks that are displayed in the Most Bookmarked in the last 30 days section of the Popular tab of the Bookmarks application.

Note: The administrator can change the number of days from 30 to something different.

To find out how to add all bookmarks to a page, retrieve the resources described in Adding a set of bookmarks to a web page and Adding a list of bookmarks to a web page.

Note: Search can only find bookmarks that the indexer has processed. The indexing interval is stored in a configuration property that your administrator can configure. See Managing search and index operations in the Administering Bookmarks section of the IBM® Connections product documentation for more details.

Resource information

/lisnippet/popular

Retrieves popular bookmarks. Returns JavaScript™ code that emits XHTML containing the search results, with each result specified in a <li> element.

/snippet/popular

Retrieves popular bookmarks. Returns JavaScript code that emits XHTML containing the search results, with each result specified in a <div> element.

Use one or more of the input parameters to narrow the search. Separate multiple parameters with an ampersand (&).

Table 1. Input parameters

Parameter

Description

custom_font

Specifies the style in which to display the list. Provide cascading style sheet (CSS) attribute:value pairs separated by semicolons to define the font style. For example: http://example.com:9083/dogear/snippet/popular?custom_font=color:black;font-size:18pt

lang

Language code. Language of the strings in the output. If not specified, the first matching browser language is used, if available. The server then redirects the request to add this parameter to the URL. Specify this parameter to avoid a redirect.

page

Page number. Specifies the page to be returned. The default value is 1, which returns the first page.

ps

Page size. Specifies the number of entries to return per page. The default value is 10. The maximum value you can specify is 50.

type

Filters the bookmarks returned in the feed. You can filter by the following values:popular
Returns a list of the most bookmarked web sites. This value is the default value.visited
Returns a list of the bookmarks that are accessed most often.

Example

You can add code similar to the HTML used in this example to display the popular bookmarks returned by either the /snippet/popular or /lisnippet/popular resource in a web page.