Participants Database
[resolved] Search form modification (6 posts)

  1. Dunger
    Posted 2 years ago #

    Is it possible when i've got only one element in search form (eg. "private_id"), to somehow remove "show all" from dropdown menu, so my own element "private_id" will be selected as default?
    I mean a situation, when the specific field will be default element in search dropdown menu.


  2. xnau
    Plugin Author

    Posted 2 years ago #


    You'll need to use a custom template to do this. Read this page on how to set one up. You will be using "pdb-list-detailed.php" as your starting point. In that template are instructions for setting up your custom drop-down. You can even leave it out completely, replacing it with a hidden field of the same name with the field name as the value.

  3. Dunger
    Posted 2 years ago #

    Thanks for your reply.
    However, i found another way:

    i've edited PDb_List.class.php

    and replaced:

    $filter_columns = array($all_string => 'none') + Participants_Db::get_field_list('search', $columns, $sort);

    $filter_columns = Participants_Db::get_field_list('search', $columns, $sort);

    And it's working :)

  4. xnau
    Plugin Author

    Posted 2 years ago #

    Yes, but it's best not to edit the core files. The templates allow you to make changes that won't be lost when you update.

  5. Dunger
    Posted 2 years ago #

    Unfortunately, i barely know html/php/css, so it's nearly impossible to me to add new line of code :( Of course your way looks even better for my purpose, but i am really green at coding.
    When it's possible, i am using templates, but this time it was way over my skills.
    Thanks for help anyway :)

  6. xnau
    Plugin Author

    Posted 2 years ago #

    I understand.... if you set aside a copy of your edited files, you can put your changes back in after upgrading.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Participants Database
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic