Title: Option filter /button filter
Last modified: March 8, 2017

---

# Option filter /button filter

 *  Resolved [chriskar07](https://wordpress.org/support/users/chriskar07/)
 * (@chriskar07)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/option-filter-button-filter/)
 * im currenntly using two buttons to filter the table as shown below
 * <button class=”table-4-filter” data-filterterm=”male”>male</button></th>
    <button
   class=”table-4-filter” data-filterterm=”female”>female</button>
 * for some weird reason i cannot use dropdown because of interference with my themes
   css
    anyway..
 * what is the equivalent with an select option type?
    for instance to get something
   like this to filter?i cant seem to find the url …./ rem.php?”search filter = ”,
   command
 * <<form action=”/rem.php”> <!– here especially! –>
    <select name=”genre”> <option
   value=”male”>male</option> <option value=”female”>female</option> </select> <
   input type=”submit” value=”Submit”> </form>

Viewing 7 replies - 1 through 7 (of 7 total)

 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/option-filter-button-filter/#post-8887635)
 * Hi,
 * thanks for your post, and sorry for the trouble.
 * You don’t need a URL for this, as this filtering works directly in the browser,
   without sending a request back to the server.
    Instead, you will need to adapt
   the JavaScript code that is in the Button Filter Extension, so that it reads 
   your selected value from the dropdown and uses that for the filtering.
 * Regards,
    Tobias
 *  Thread Starter [chriskar07](https://wordpress.org/support/users/chriskar07/)
 * (@chriskar07)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/option-filter-button-filter/#post-8888739)
 * hey Tobias
    thank you for your reply
 * could you kindly give an example of what it would look like?
 * thank you for your time!
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/option-filter-button-filter/#post-8888776)
 * Hi,
 * not really, sorry. I can only suggest that you try to understand and adapt the
   JS code of the current Button Filter.
 * Regards,
    Tobias
 *  Thread Starter [chriskar07](https://wordpress.org/support/users/chriskar07/)
 * (@chriskar07)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/option-filter-button-filter/#post-8888850)
 * ok cool i understand! thanks!
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 3 months ago](https://wordpress.org/support/topic/option-filter-button-filter/#post-8888991)
 * Hi,
 * no problem, you are very welcome! I hope that you can find a good solution!
 * Best wishes,
    Tobias
 *  Thread Starter [chriskar07](https://wordpress.org/support/users/chriskar07/)
 * (@chriskar07)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/option-filter-button-filter/#post-8928211)
 * im still trying with no succesful results, could you please give me a hint
    on
   how to change the button filter to accept value on submit?
 *     ```
       var {$name} = {$command};
       $( 'body' ).on( 'click', '.table-{$table_id}-filter', function() {
       	{$name}.search( $( this ).data( 'filterterm' ) ).draw();
       } ); 
       ```
   
 *  Plugin Author [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * (@tobiasbg)
 * [9 years, 2 months ago](https://wordpress.org/support/topic/option-filter-button-filter/#post-8954072)
 * Hi,
 * sorry for the long wait, as I was on holidays, I could not reply earlier.
 * Sorry, this is beyond what I can help with at the moment. It’s been a while since
   I wrote that JS code, so that I would first have to understand what I did there
   again. You would probably have to use a different jQuery event listener and then
   retrieve the selected dropdown value.
 * Regards,
    Tobias

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Option filter /button filter’ is closed to new replies.

 * ![](https://ps.w.org/tablepress/assets/icon.svg?rev=3192944)
 * [TablePress - Tables in WordPress made easy](https://wordpress.org/plugins/tablepress/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/tablepress/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/tablepress/)
 * [Active Topics](https://wordpress.org/support/plugin/tablepress/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/tablepress/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/tablepress/reviews/)

 * 7 replies
 * 2 participants
 * Last reply from: [Tobias Bäthge](https://wordpress.org/support/users/tobiasbg/)
 * Last activity: [9 years, 2 months ago](https://wordpress.org/support/topic/option-filter-button-filter/#post-8954072)
 * Status: resolved