Make WordPress Core

Opened 19 years ago

Closed 19 years ago

#2592 closed defect (bug) (fixed)

Add selected list of categories option to function get_bookmarks()

Reported by: michaelh's profile MichaelH Owned by: michaelh's profile MichaelH
Milestone: 2.1 Priority: normal
Severity: normal Version: 2.1
Component: Administration Keywords: bookmarks has-patch bg|needs-testing
Focuses: Cc:

Description

In anticipation of the template function: wp_list_bookmarks (ticket:2587), add the option to return bookmarks belonging to a selected list of categories.

Attachments (1)

selected_cats_for_get_bookmarks.diff (2.2 KB) - added by MichaelH 19 years ago.
Selected categories for get_bookmarks

Download all attachments as: .zip

Change History (4)

@MichaelH
19 years ago

Selected categories for get_bookmarks

#1 @MichaelH
19 years ago

  • Keywords has-patch bg|needs testing added

Patch to function get_bookmarks(), allows a parameter such as 'category=1,3,7' to return only bookmarks belonging to those three categories.

Also, changed so that $category = '' returns ALL categories (previously, $category = -1 returned ALL). This required adding line in get_links() to pass $category correctly when calling get_bookmarks().

Also fixed problem in get_links_list() to report bookmarks that only belong to a "child category" by adding &hierarchial=0 to the parameter list when calling get_categories().

#2 @davidhouse
19 years ago

  • Keywords bg|needs-testing added; bg|needs testing removed

#3 @ryan
19 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [3658]) Retrieve bookmarks for multiple cats. Props MichaelH. fixes #2592

Note: See TracTickets for help on using tickets.