Ask AI
Skip to main content

Route to page

Function: Route to page

This function allows you to seamlessly guide your users to a different page within your application. It's a fundamental tool for navigation, enabling you to direct users to confirmation pages, detail views, or any other part of your application based on their actions or specific conditions.

Input

  • Template: (Required) The specific page in your application that you want to send the user to. You will typically select this from a list of your existing pages.
  • Template parameters: (Optional) If the target page needs specific information to display correctly (for example, an item ID for a product detail page, or a user ID for a profile page), you can pass that information here. These are like special instructions or data that the new page will use when it loads.
  • Force route: (Optional) A "Yes/No" switch. If set to "Yes", the system will always navigate to the new page, even if the user is already on that page. If set to "No", the system might prevent an unnecessary reload if the user is already viewing the target page.
  • Target: (Optional) This dropdown allows you to choose how the new page should open:
    • Self: The new page will open in the same browser window or tab, replacing the current page.
    • New window/tab: The new page will open in a brand new browser window or tab, leaving the current page open.

Output

This function does not produce any direct output variables that you can use in subsequent actions. Its primary effect is to change the page displayed to the user in their browser.

Execution Flow

Real-Life Examples

Here are a few scenarios demonstrating how you can use the "Route to page" function:

  1. Navigating after a form submission

    • Scenario: A user has successfully filled out and submitted a "Contact Us" form. You want to show them a confirmation.
    • Inputs:
      • Template: "Thank You Page"
      • Template parameters: (Empty, as the thank you page doesn't need specific data)
      • Force route: No
      • Target: Self
    • Result: The user is immediately taken to the "Thank You Page" within the same browser tab, confirming their submission and providing next steps.
  2. Displaying product details from a list

    • Scenario: A user clicks on a product in a catalog list. You want to show them the detailed information for that specific product.
    • Inputs:
      • Template: "Product Detail Page"
      • Template parameters: \{"productId": "P12345"\} (assuming your "Product Detail Page" is designed to receive a productId to fetch and display the correct product information)
      • Force route: No
      • Target: Self
    • Result: The application navigates to the "Product Detail Page", which then displays all the specific details for the product with ID "P12345".
  3. Opening a help article in a new tab

    • Scenario: A user clicks a "Help" button while working on a task. You want to open a relevant help article without interrupting their current work.
    • Inputs:
      • Template: "Help Article: Getting Started"
      • Template parameters: (Empty)
      • Force route: Yes (to ensure it always opens, even if they somehow already have it open)
      • Target: New window/tab
    • Result: A new browser tab or window opens, displaying the "Getting Started" help article, allowing the user to refer to it while keeping their original task page open.