1. The next step is to formulate the URL and add it into the 'Custom URL' section of the form settings. This allows for people to enter in values into the form, and have the URL populate with those values in order to display only the records that match.
2. It's worth mentioning the basic variables and the basic format. "searchFor" variables allows users to search for certain values, and the results will display if ANY of the searchFor values match. "searchFilter" is very similar, except results will only display if ALL of the searchFilter values match. (Think amazon or any mainstream website where you need to filter your results...that's the idea here)
3. Before we create the URL, the basic format for both searchFor and searchFilter is "searchFor" or "searchFilter" followed by "=", followed by the field you're searching for, followed by a colon, followed by the value you're searching for. Example: searchFilter=Field name:Value NOTE: Non-text fields can use certain delimiters that use something other than a colon. Refer to the advanced tips section for reference.
4. Now that we understand the basic formatting, we're ready to create the the URL. Click into the form settings, click the 'Custom URL' option, then click into it.
5. First, add the published page's domain. In our example, the domain is https://joblistingpage.safechkout.net/.
6. After the domain, add a '?'. So it's https://joblistingpage.safechkout.net/?
7. On our example page, we're going to have the 'Job title' use the searchFor variable, so that we can search for a job title and see any results that match, plus only include the additional filter values. If we wanted to include 'Job title' as a searchFilter, we could do that also, so we would only see results that match that job title and any of the other filters.
We'll take our URL "https://joblistingpage.safechkout.net/?" and add searchFor=Job title:", so the full URL will be: https://joblistingpage.safechkout.net/?searchFor=Job title:
8. Next, we need to add the filter variables for each field that's on the page/each field that we want to filter off of. So using the URL up to this point, we'll add a "&", followed by "searchFilter=", followed by the field name, followed by a colon, followed by the merge field. Below I'll list out some examples
9. Using the URL from step 7, we'll follow the same format for the "Department" field. So we'll take our URL, add a "&", followed by "searchFilter=", followed by the field name, colon, merge field. So the URL: https://joblistingpage.safechkout.net/?searchFor=Job title:
will become: https://joblistingpage.safechkout.net/?searchFor=Job title:&searchFilter=Department:.
10. We'll repeat this until we have each field added. However, instead of adding a new searchFilter for each new field, we can separate fields and values with semicolons. So to add the "Experience" field to the URL from step 9, it will become https://joblistingpage.safechkout.net/?searchFor=Job title:&searchFilter=Department:;Experience:.
Repeat this same format for all fields on the form.
11. Note on numeric and price fields: In our example, we're using "Minimum salary". So we can use searchFilter=Minimum salary:value, and that will filter records for that exact value. However, people may want to see any salary equal to or greater than the value. In that case, instead of adding a colon, we can add a ">=". So it will be searchFilter=Minimum salary>=value. Using >= is HIGHLY recommended, because if you don't fill out numeric field, the merge field will still populate as 0. And unless the "minimum salary" is equal to 0, no results will display. Refer to advanced tips section for the other numeric delimiters.
12 We also have two additional fields called 'Sort by' and 'Sort order'. You may have noticed that these fields weren't in the Job listing object. That's because these fields and the corresponding values will allow us to sort by a particular field, and sort either ascending or descending. And they don't need a value in the record object to make this work. We just need these fields in the Contact object in order to make them work off of the form submission. In the sort by field, we have "Department" and "Salary". In sort order, the values are "Ascending" and "Descending".
The format for sort by is sortby=
The format for sort order is sortorder=[Sort by minimum salary]
They essentially follow the same format as other fields, except it's the sortby or sortorder variable name, followed by equal sign, followed by the value.
The only values that will work for sortorder are "ascending","descending", "desc", or "asc". So those values must be in the Contact field on the form in order to work.
The sortby field values must be one of the field names that exist in the job listing object, because we're choosing to sort based off of one of those fields.
Both of these options exist in dynamic block display settings, but by adding them into the URL, they'll overwrite the block settings and sort the records based on values in the form.
We also want to add these to the end of the URL. The reason we add this to the end is because if you have multiple sortBy variables in your URL and they're not targeting a specific block, they could have conflicts. And we'll only use the lasts sortBy variable found in the URL in that instance. So it's not required but recommended to add them to the end of your URL, unless you're including these variables in different blocks.
12. Once you've added all of the fields from the form, the full URL should be: https://joblistingpage.safechkout.net/?searchFor=Job title:&searchFilter=Department:;Experience:;Location:;Minimum salary>=;Education:;Degree required:No&sortBy=&sortOrder=[Sort by minimum salary]