RedirectTo
→ voidSpecifies the target of an email link as a complete URL from an attribute, data extension field, or variable. Use inside the href of HTML emails per WS-FUEL / AMPscript patterns.
Available in:
Email
CloudPage
Automation
Triggered Send
Syntax
Platform.Function.RedirectTo(url)
1 argument
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
url |
string | Yes | Complete URL to use as the link target |
Example
var email = "aruiz@example.com";
var firstName = "Angela";
var baseUrl = "https://example.com?email=";
var nameJoin = "&name=";
Platform.Function.RedirectTo(baseUrl.concat(email, nameJoin, firstName));
In HTML email content, use inside href as %%=RedirectTo(...)=%% per your sender setup.
For CloudPages HTTP redirects, use Platform.Response.Redirect instead.