Make WordPress Core

Opened 12 years ago

Closed 11 years ago

Last modified 11 years ago

#24073 closed defect (bug) (invalid)

wp_ajax_ajax_tag_search

Reported by: samnajian's profile samnajian Owned by:
Milestone: Priority: normal
Severity: normal Version: 3.5.1
Component: Taxonomy Keywords: reporter-feedback
Focuses: Cc:

Description

For some of custom taxonomies the tag autocomplete doesn't work I tried to solve this issue and changing t.name to name in

$results = $wpdb->get_col( $wpdb->prepare( "SELECT name FROM ..... ");

in wp-admin/includes/ajax-actions.php -> wp_ajax_ajax_tag_search() helped me to solve this problem.

now everything looks ok for me .

Change History (4)

#1 @SergeyBiryukov
12 years ago

  • Component changed from General to Taxonomy
  • Keywords reporter-feedback added

Could you provide a piece of code and the steps to reproduce the issue on a clean install?

The change doesn't seem to make any difference. t is a reference to $wpdb->terms in that query:
http://core.trac.wordpress.org/browser/tags/3.5.1/wp-admin/includes/ajax-actions.php#L75

Since $wpdb->term_taxonomy doesn't name column, t.name and name are the same here.

Version 0, edited 12 years ago by SergeyBiryukov (next)

#2 @samnajian
12 years ago

HI,
I've installed event-manager plugin and it adds new taxonomies to the system, for this plugin i didn't get tag autocomplete and then I traced the ajax action and came up to this sql query but changing t.name to name changed the result and the problem was solved.
Now i get autocomplete for all the taxonomies registered in the system ( default taxonomies and custom taxonomies).
The code and files are those I provided in the ticket.

#3 @webord
11 years ago

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

Seems that It's a plugin specific problem, because I could not reproduce it here.

I've registered a Taxonomy to post Post type, and created some terms, and the autocomplete seems ok.

#4 @helen
11 years ago

  • Milestone Awaiting Review deleted
Note: See TracTickets for help on using tickets.