Make WordPress Core

Opened 16 years ago

Closed 15 years ago

#7647 closed defect (bug) (duplicate)

Search function does not include image descriptions

Reported by: langsuyar's profile langsuyar Owned by:
Milestone: Priority: normal
Severity: normal Version:
Component: General Keywords: needs-patch
Focuses: Cc:

Description

  • Create a post
  • Create an image attachment for that post
  • Enter a image description for the attachment
  • Perform a search that uses one of the names from the image description
  • Wordpress won't display the image pages in the search results.

Technically, image descriptions and post content might be different, but image descriptions are displayed in exactly the same manner as post text when the ?atttachmen_id= page is loaded. It is counterintuitive that a blog search does not find any of the attached images.

Change History (6)

#1 @Denis-de-Bernardy
15 years ago

  • Keywords needs-patch added
  • Milestone changed from 2.8 to Future Release

I'm tempted to close this as dup. there are so many "search in everything" tickets already...

#2 @lgedeon
15 years ago

  • Cc lgedeon added

I am still learning the WordPress system and with it php (veteran of several other languages though). I have written one plug-in so far, but still have a lot to learn. So I am not going to pretend to speak with authority. :)

I did look around for similar tickets. Some of them are for other areas that have since been added to search or are covered by plugins, but I did not see this particular issue. Plus, this seems to be particularly well written. I have no authority, but I'll vote for it anyway.

It is something I would actually be interested in working on. Is anyone available to point me in the right direction? I am willing to do the grunt work, and I am doing the research now, but any advice would be appreciated.

#3 @Denis-de-Bernardy
15 years ago

it's in wp-includes/query.php

currently, WP searches in posts, and returns the results (of a like statement) ordered by date desc.

a custom query will reveal a bunch of posts with a description or a summary with search in it. you'll find tons of tickets related to searching in pages, in images, in comments, basically everywhere. not to mention the strong desire to order results by relevance.

#4 @Denis-de-Bernardy
15 years ago

  • Milestone Future Release deleted
  • Resolution set to fixed
  • Status changed from new to closed

see #9785

#5 @Denis-de-Bernardy
15 years ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

#6 @Denis-de-Bernardy
15 years ago

  • Resolution set to duplicate
  • Status changed from reopened to closed
Note: See TracTickets for help on using tickets.