Viewing 12 replies - 1 through 12 (of 12 total)
  • Plugin Contributor Stef (a11n)

    (@erania-pinnera)

    Hi there, @naturundtierverlag,

    Thanks for explaining your issue and for doing some initial troubleshooting.

    Before escalating this to our developers, I’d like to check for any other potential conflicts that might be part of the problem. Can you please test the following:

    • Try disabling all plugins except for WP Job Manager to see if the issue persists. If it stops, the issue is with one of the plugins you’ve deactivated. Reactivate each, one by one, until you’ve found the offending plugin.
    • If the problem is still there when all plugins are deactivated, it’s likely your theme causing the issue. Try switching to a default theme (like Twenty Twenty) to see if the issue persists.

    Make sure you take a database backup before making any changes to the website for safety reasons, and let us know how it goes. Thanks!

    Thread Starter naturundtierverlag

    (@naturundtierverlag)

    Hi, thanks for the reply!

    I’ve deactivated my plugins one by one, repeatedly checking if the generated URL had changed. Sadly, no success.

    The theme I use is a customized “Child” version of Listify. There is no change if I switch to the standard version. If I switch to the “Twenty Twenty” theme, the search form is changed to a simple text box and I can no longer select the listing category in the first place.

    Hello @naturundtierverlag,

    I have tried today and if I understand correctly, the search page is working correctly, is this right? Did you manage to find what the issue was? Was it caused by WP Job Manager?

    Thread Starter naturundtierverlag

    (@naturundtierverlag)

    Hi, it’s very weird. The first search works, but from the second one onwards, the category is always set to the one from the first search. Only if I manually correct the URL by removing the “[]” (in Firefox) or “%5B%5D” (in Chrome) the right one is selected.

    Hey @naturundtierverlag I gave it another go and again I can’t see the issue. When I click the link that you sent I get a screen that just dsiplays the ‘MEINING TERRARISTIK’ listing which looks correct.

    I then try different categories (e.g. ‘Sonstiges’) and I get different results. When I try other categories, I also verify that a different category id is sent in the AJAX request that fetches the listings.

    You can also verify this yourself by opening the Web Developer tools in Chrome or Firefox, open the network tab and check the payload of the jm-ajax/get_listings requests that are sent to the server when you perform a new search.

    On a side note, if you expect the URL to get updated to reflect the category change, this will not happen as the updates happen by an AJAX call and this is not reflected in the URL.

    Thread Starter naturundtierverlag

    (@naturundtierverlag)

    Hi,

    thanks for trying it again. I probably didn’t communicate the issue correctly. The search form I was talking about is located on the front page of the website: https://www.terrarium-wissen.de/verzeichnis/

    Searches made on the front page generate URLs like this one: https://www.terrarium-wissen.de/verzeichnis/listings/?search_keywords=&search_location=&search_categories%5B%5D=57&search_radius=50&search_lat=0&search_lng=0&search_region=

    These lead to a page correctly showing the selected category for the first search. However, if you navigate back to the front page and search again with a different category, the one selected for the first search is shown.

    If I change the generated URL to not contain the brackets (“[]” in Firefox, “%B%5D” in Chrome), the category is selected correctly.

    So when I do a search in the ‘verzeichnis’ page (https://www.terrarium-wissen.de/verzeichnis/) I am redirected to a page with a URL similar to what you sent. However, when I navigate back the URL is normally set back to https://www.terrarium-wissen.de/verzeichnis/ again. So it is not possible to reproduce the issue.

    Something, that I have observed though, is that the https://www.terrarium-wissen.de/verzeichnis/ page is custom made and as this forum is about supporting WP Job Manager plugin only, this page is outside the scope of our support.

    Let us know if you think that you found an issue with the plugin itself and apologies for not being able to provide any help here.

    Thread Starter naturundtierverlag

    (@naturundtierverlag)

    Hi,

    thanks for the effort. The code called here is from WP Job Manager though, is it not?

    <?php do_action( 'job_manager_job_filters_end', $atts ); ?>

    Is there any way to modify this? I would like to see the exact place where the URL is generated before I’m ready to give up.

    Yes this code is from WP Job Manager and it exists in job-filters.php template.

    You can have a look at this page on how you can override this template with your own version: https://wpjobmanager.com/document/developer-reference/themes/template-overrides/

    Thread Starter naturundtierverlag

    (@naturundtierverlag)

    I was talking about the code called here, specifically

    job_manager_job_filters_end()

    Can I access this as well?

    It depends on what you want to do with it. If it is for debugging purposes, you can access everything. The specific function is in class-job-manager-job-tags-shortcodes.php file.

    If you want to modify in a way that the code is not overwritten when you update the plugin, then no.

    Thread Starter naturundtierverlag

    (@naturundtierverlag)

    I’ll see what I can do – thanks.

Viewing 12 replies - 1 through 12 (of 12 total)
  • The topic ‘Listing Search generates wrong URL’ is closed to new replies.