Support » Fixing WordPress » How to add a search to a custom page in admin?

  • Hi everyone,

    Wonder if anyone can point me in the right direction here.

    I have created a plugin (kind of – it’s more like a set of functions in the theme) which allows the user to add events to a list to be able to display on a site. However, I’d like the ability to search those events in the admin side as it’s likely the list will get long.

    Unfortunately the only search boxes I can reference are the ones on the Posts page, Pages page, Categories page (etc) which all use the query string ?s=searchterm. My page however is not displayed that way – it simply links to admin.php?page=my_events_page and it will not accept an additional query so I cannot search my list.

    I hope I am explaining this clearly enough – basically I want to be able to search my own admin page content, so any help is appreciated. Otherwise it’s going to be a case of finding it manually by trawling through each page of events…


Viewing 2 replies - 1 through 2 (of 2 total)
  • Nile Flores


    Yoast Support

    There is a plugin called Search Everything in the WordPress plugins directory that does something to that.

    I would say you need to make sure your functions are dedicated to the backend, rather than the front end. Maybe that plugin, if you take a look at the code, might help you on your way.

    Thanks, I will take a look at that now 😀

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘How to add a search to a custom page in admin?’ is closed to new replies.