Redirect — Reference
Send an HTTP redirect to another URL and end this response.
Send an HTTP redirect to another URL and end this response.
Before you begin
Section titled “Before you begin”- An open Server Connect action. Runtime differences below refer to the installed Node.js and PHP implementations.
Redirect
Section titled “Redirect”Send an HTTP redirect to another URL and end this response.
Settings and execution
Section titled “Settings and execution”| Setting | Meaning |
|---|---|
| Name | Optional identifier for the action step. It does not become a returned data object. |
| Url | The redirect destination. For example, /account sends a browser navigation request toward that path. Validate any destination derived from user input. |
| Status | The inspector offers 301, 302 and 303, with 302 when omitted. Node.js uses the requested numeric status. The installed PHP implementation maps any non-301 choice to 302, so a configured 303 does not behave identically there. |
Worked example
Section titled “Worked example”In a test endpoint called through a normal browser navigation, redirect to /account using 302. Inspect the redirect status and Location header, then confirm that the browser reaches the destination.
Check the behavior and limits
Section titled “Check the behavior and limits”An App Connect data request following a server redirect does not by itself navigate the top-level page. For a successful AJAX login form, use the page’s success event and a Browser navigation action when the desired behavior is to change pages.
Continue with a task
Section titled “Continue with a task”Use the Server Connect guides when you need the surrounding project, data-loading or form procedure.
Check your result
Section titled “Check your result”You can configure Redirect deliberately and verify the result and failure behavior described in this reference.