• Resolved fransjansen

    (@fransjansen)


    Hi Antonine,

    I activated the user search plugin, but there is no searchbar visible on the ranking page. What am I doing wrong?

    I did the same for the pagination plugin, also with the same result. I only saw the top 10 of the ranking but I could not navigate to another page. I removed this plugin, but probably it is causes by the same issue.
    Hopefully you can help to solve it.

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author AntoineH

    (@antoineh)

    Hi Frans,

    Both the user search and the pagination plugin hook into a filter for the page class output footballpool_ranking_page_html. So it will only work for the page that is selected in the plugin options. Not sure if this is the case in your install or if you are using the shortcodes or widgets.

    That being said, I’m not sure if a) these plugins can work together (because they both try to filter the ranking) and b) if the user search still works because it hasn’t been touched since 2018 and I know that I’ve made changes to the way that the ranking page builds the data array. I tested the pagination recently and that one looked like it still works.

    Thread Starter fransjansen

    (@fransjansen)

    That makes sense. I am using shortcode to display the ranking. The main reason I am using this is the fact that I wanted to have two sidebars (left and right) on desktop view. I could not achieve this on the regular ranking page: https://ek2021pool.nl/ranking/

    But as you can see the searchbar is displayed on that page. No worry. I do not really need it, but I think it was a nice addition.

    Plugin Author AntoineH

    (@antoineh)

    I can check this weekend if the search plugin still works, because only then it would make sense to try to get it to work with the shortcode.

    That’s a small disadvantage of the extensions: I provide them as-is and mainly as an example (as proof that the vanilla plugin can be extended in lots of different ways). I never intended to give official support for them.

    Plugin Author AntoineH

    (@antoineh)

    Nevermind, I found some spare time before dinner ??

    I checked the user search with the shortcode and it looks like it will work fine if you change the filter for the add_search callback to the one that is used in the shortcode.

    So line 25 should be:
    add_filter( 'footballpool_shortcode_html_fp-ranking', array( __CLASS__, 'add_search' ) );

    Disclaimer: I did not thoroughly test it, so no guarantees it will also work in your install and I also did not check if the user search works for the normal ranking page.

    Thread Starter fransjansen

    (@fransjansen)

    Great. Thanks Antoine.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘User search not visible’ is closed to new replies.