When you integrate a Search block into your app, you're equipping your members with a powerful content discovery tool. As a creator, you have complete control over the search criteria when configuring the Search block, meaning each Search block you include in your app can be customised to be as broad or specific as you like.
Read on to learn how to set up search functionality in your own app:
Adding the Search Block to a Page:
In the Movement admin, navigate to the page where you want to include search functionality.
Hit the [+Add Block] button or the purple ‘+Block’ button that appears if you’re hovering over an existing block.
In the ‘Add Block’ menu, navigate to the ‘Search’ category.
4. In the ‘Search’ category, click or drag on the Search block you want and it will be added to the page.
5. Now that the Search block is added to the page, you can customise it to your needs.
Configuring the Search Block
Now that you’ve added the Search block to your page, its time to customise it. If you do not specify any content types or filters (tags) in the search block, it will function as a global search. This means it will return all content or pages within your app that match or contain the text entered by the member in the search bar. This kind of global search can be great to include on the homepage of your app, allowing for quick content discovery and access. If you’d like to set up a more specific search experience that only displays content relevant to a particular page or program (e.g. a meal library), read on:
Choose the content type(s) you’d like to appear in the search.
Click on the Search block and you will notice a ‘Search’ panel appears in the righthand sidebar.
The ‘Included Content Types’ section is where you can specify which content types will appear in the search results for user.
In this example, we will add a Search block to the main page of our meal library, so we only want content from the ‘Meal’ content type to be displayed in the search results . Click on the ‘Select a Content Type’ input field and a list of all of the content types in your app will appear. In this example we will select ‘Meal’ from the list.
💡 Note: If you do not specify any content types in ‘Included Content Types’, this search block will return results from all content types.
4. Hit ‘Save & Publish’ and now this search block will only return results from the ‘Meal’ content type.
5. To test it out hit the [Preview] button next to the [Share] button in the top righthand side of the admin.
6. You will notice the results populate with all of the content items in the ‘Meal’ content type.
7. When a member types something in the ‘Search’ field, the results will get more specific and the list will only contain items from the specified content type that match or contain the text entered by the member.
Make searches even more specific with tag filtering:
If you’d like to make your searches more specific, you can specify which tags a content item or page must contain to be displayed in the search results:
In this example, we will further refine our search so only Meals containing the ‘Breakfast’ tag will be displayed to the user in their search results.
Click on the Search block click the ‘With Tags’ checkbox in the ‘Filters’ section so a green tick appears.
💡 Note: Members will only see content that aligns with the parameters you establish in the search block in their search results. This could range from broad, app-wide searches to more specific queries based on content type. The flexibility of the tag system further refines this process. By selecting ‘With All Tags’, the search results will display content that includes every tag you specify, creating a highly specific search experience. Conversely, choosing ‘With Any Tags’ broadens the scope, showing content that contains at least one of the specified tags, if you have selected multiple.
2. Click on the ‘Select a tag’ input field and a list of all of the tags in your app will appear. In this example we will select ‘Drink’ from the list.
3. One you’ve selected which tags the content must contain to appear in the search results for this search block, hit ‘Save & Publish’.
4. In this example, only content in the ‘Meal’ content type that is tagged with ‘Drink’ will appear in search results for this Search block.
5. As you can see above, our previous Search for ‘Chocolate’ will now return 2 results instead of 3, as the Banana Chocolate Protein Balls meal does not contain the ‘Drink’ tag.