I am relatively new to WordPress theme development, so there are still a few things that I have not come across.

I created a basic WordPress theme and my client is unable to search the media library. No matter what you type in, nothing is retrieved. Whether you type in the image title, filename etc... nothing shows up.

I am guessing I have to enable this somewhere, perhaps in my functions.php but I can't find anything about this online. Would someone kindly be able to advise?

Many thanks!

  • You want to search the attachments from the front-end main search? – birgire Jan 15 '18 at 15:54
  • Hello, No sorry, I want to be able to search the media library on the dashboard/admin area. – rebeccasmith_me Jan 15 '18 at 16:04
  • So when you go to the Media library in the backend, the search there finds nothing? Maybe you've got some code in your theme or a plugin that's interfering with the backend search? (e.g. pre_get_posts action callback? ) – birgire Jan 15 '18 at 16:43
  • 1
    Ah! Thank you so much. Yes, I had narrowed it down to posts. I didn't realise it changed the media library search. Clearly, I still have a lot to learn. Thank you again :) – rebeccasmith_me Jan 15 '18 at 17:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.