Linking homepage search to attributes filter page

Hello, I’ve seen other people raise this topic but I can’t seem to repeat their solutions. Search from homepage using filters and query params (?*=)

I have a homepage search that I would like to populate the CMS filter search field on a different page.

I’ve seen other people suggest custom JS to complete the search functionality, which I’ve copied and tweaked, but I can’t seem to get it to work for me.

Here is the read-only: Webflow - You Recruitment

The homepage is trying to link to the Job Board page.

Can anyone tell me where I’m going wrong?

hey @jacob2! You have some different id on your elements and the code, this is why it fails.

Try using these selectors

const userInput = document.getElementById('search-all-2');
const locationCategory = document.getElementById('location');
const form = document.getElementById('wf-form-Job-Search');

Let me know if you face any other issue :wink:

Thanks @Support-Luis - what a silly mistake!

I’ve made that change and it still seems to be doing the same URL result: rather than the *=term we need.

I noticed other people using the Query Param attribute, I’m not sure it I need to apply those attributes anywhere?

I got this to work by moving the JS from the head to the body

Hey @jacob2! That’s great to hear!

I’ve also noticed you got the *= field working. Great :raised_hands: