WordPress.org

Ready to get started?Download WordPress

Forums

How to add a search to a custom page in admin? (3 posts)

  1. f00bar
    Member
    Posted 4 years ago #

    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...

    Thanks
    Michael

  2. Nile Flores
    Member
    Posted 4 years ago #

    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.

  3. f00bar
    Member
    Posted 4 years ago #

    Thanks, I will take a look at that now :D

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags