{"id":31346,"date":"2018-04-21T15:47:45","date_gmt":"2018-04-21T15:47:45","guid":{"rendered":"https:\/\/ampscript.guide\/system-strings\/"},"modified":"2022-07-26T16:25:56","modified_gmt":"2022-07-26T16:25:56","slug":"system-strings","status":"publish","type":"post","link":"https:\/\/ampscript.guide\/system-strings\/","title":{"rendered":"System Strings"},"content":{"rendered":"<h2>System Strings<\/h2>\n<p>Marketing Cloud includes a library of system-based personalization strings which can be included in a message or on a page to output a value, based on the context of the Subscriber, Contact or a message.<\/p>\n<h3>Email Date Strings<\/h3>\n<blockquote>\n<p>NOTE: Date-based personalization strings use the system time (the data center location of your Marketing Cloud account) and appear in US format. However, these values can be transformed using AMPscript <a href=\"\/date-and-time-functions\">date functions<\/a>.<\/p>\n<\/blockquote>\n<table>\n<thead>\n<tr>\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"text-align: left;\"><code>xtmonth<\/code><\/td>\n<td style=\"text-align: left;\">Full name of the month when email is sent<\/td>\n<td style=\"text-align: left;\"><code>January<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>xtmonthnumeric<\/code><\/td>\n<td style=\"text-align: left;\">Current month as a number<\/td>\n<td style=\"text-align: left;\"><code>1<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>xtday<\/code><\/td>\n<td style=\"text-align: left;\">Current day of the month when the email was sent<\/td>\n<td style=\"text-align: left;\"><code>15<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>xtdayofweek<\/code><\/td>\n<td style=\"text-align: left;\">Current day of the week when the email was sent<\/td>\n<td style=\"text-align: left;\"><code>Monday<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>xtyear<\/code><\/td>\n<td style=\"text-align: left;\">Current year when the email was sent<\/td>\n<td style=\"text-align: left;\"><code>2018<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>xtshortdate<\/code><\/td>\n<td style=\"text-align: left;\">Current date when the email was sent in short format<\/td>\n<td style=\"text-align: left;\"><code>01\/15\/2018<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>xtlongdate<\/code><\/td>\n<td style=\"text-align: left;\">Current date when the email was sent in long format<\/td>\n<td style=\"text-align: left;\"><code>Monday, January 15, 2018<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Example<\/h4>\n<p>This example will update a date field in a Data Extension with the system time when an email is sent, which can be used as a suppression Data Extension for future sends:<\/p>\n<pre><code>%%[\n\nInsertDE(\"Sent Subscribers\", \"Member ID\", _subscriberkey, \"sent date\", xtshortdate)\n\n]%%<\/code><\/pre>\n<h3>Email Data Strings<\/h3>\n<table style=\"width:100%;\">\n<colgroup>\n<col style=\"width: 9%\">\n<col style=\"width: 79%\">\n<col style=\"width: 11%\">\n<\/colgroup>\n<thead>\n<tr class=\"header\">\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>emailname_<\/code><\/td>\n<td style=\"text-align: left;\">Name assigned to the email<\/td>\n<td style=\"text-align: left;\"><code>Spring Newsletter<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_emailid<\/code><\/td>\n<td style=\"text-align: left;\">The system-defined numeric identifier of the email<\/td>\n<td style=\"text-align: left;\"><code>33345<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_messagecontext<\/code><\/td>\n<td style=\"text-align: left;\">\n<p>The context in which the Subscriber viewed the message or page. Either:<\/p>\n<ul>\n<li>\n<code>SEND<\/code> \u2013 an email that is sent to a Subscriber<\/li>\n<li>\n<code>PREVIEW<\/code> \u2013 an email that is previewed within the email editor<\/li>\n<li>\n<code>VAWP<\/code> \u2013 an email opened as &#8220;view as web page&#8221; (from a <code>view_email_url<\/code> link in an email)<\/li>\n<li>\n<code>FTAF<\/code> \u2013 an email that is sent as a &#8220;Forward to a Friend&#8221; message<\/li>\n<li>\n<code>LANDINGPAGE<\/code> \u2013 content is viewed on a landing page, microsite page or CloudPage code resource<\/li>\n<li>\n<code>VALIDATION<\/code> \u2013 email is validated using the validation option in Marketing Cloud<\/li>\n<li>\n<code>LINKRESOLUTION<\/code> \u2013 a URL in an email that is resolved as a click-through link<\/li>\n<li>\n<code>SMS<\/code> \u2013 an SMS message that is sent to a Subscriber<\/li>\n<li>\n<code>SOCIAL<\/code> \u2013 email content that is shared using the <a href=\"https:\/\/help.marketingcloud.com\/en\/documentation\/exacttarget\/content\/social_forward\/\">Social Forward<\/a> feature<\/li>\n<\/ul>\n<\/td>\n<td style=\"text-align: left;\">Refer to Description<\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_replycontent<\/code><\/td>\n<td style=\"text-align: left;\">Used in a Triggered Send Email that has been set as the &#8220;Triggered send to forward&#8221; option in a Sender Profile when Reply Mail Management is configured. Returns the email body that was included in the reply message.<\/td>\n<td style=\"text-align: left;\">Refer to Description<\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_IsTestSend<\/code><\/td>\n<td style=\"text-align: left;\">Resolves to <code>true<\/code> if the email was sent as a Test Send from Email Studio, otherwise the value is <code>false<\/code>\n<\/td>\n<td style=\"text-align: left;\"><code>false<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>jobid<\/code><\/td>\n<td style=\"text-align: left;\">Returns the unique job identifier related to the email send<\/td>\n<td style=\"text-align: left;\"><code>3210123<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_JobSubscriberBatchID<\/code><\/td>\n<td style=\"text-align: left;\">A numeric identifier of the batch associated with a Triggered Email; this value defaults to <code>0<\/code> for a List send<\/td>\n<td style=\"text-align: left;\"><code>5554321<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_PreHeader<\/code><\/td>\n<td style=\"text-align: left;\">The preheader attribute assigned to the email. This string only returns a value when used in an <a href=\"#anchor_AttributeValue\">AttributeValue<\/a> function. For example, <code>%%=AttributeValue(\"_PreHeader\")=%%<\/code>\n<\/td>\n<td style=\"text-align: left;\"><code>30% off store-wide, this weekend only!<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_DataSourceName<\/code><\/td>\n<td style=\"text-align: left;\">The value of the List, Group, Sendable Data Extension or Data Extension Filter related to the email send; returns an empty value if the All Subscribers list is used<\/td>\n<td style=\"text-align: left;\"><code>VIP Members<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_listname<\/code><\/td>\n<td style=\"text-align: left;\">The user-defined list name; returns an empty value if the All Subscribers list is used<\/td>\n<td style=\"text-align: left;\"><code>Loyalty Members<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Subscriber Data Strings<\/h3>\n<table>\n<thead>\n<tr>\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"text-align: left;\"><code>emailaddr<\/code><\/td>\n<td style=\"text-align: left;\">The email address of the Subscriber<\/td>\n<td style=\"text-align: left;\"><code>leon@limedash.com<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>firstname_<\/code> or <code>firstname<\/code><\/td>\n<td style=\"text-align: left;\">The Subscriber&#8217;s first name from the &quot;FirstName&quot; Subscriber Profile Attribute<\/td>\n<td style=\"text-align: left;\"><code>Leon<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>lastname_<\/code> or <code>lastname<\/code><\/td>\n<td style=\"text-align: left;\">The Subscriber&#8217;s last name from the &quot;LastName&quot; Subscriber Profile Attribute<\/td>\n<td style=\"text-align: left;\"><code>Green<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>subscriberid<\/code><\/td>\n<td style=\"text-align: left;\">A system-defined numeric identifier representing a Subscriber<\/td>\n<td style=\"text-align: left;\"><code>1234<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>_subscriberkey<\/code><\/td>\n<td style=\"text-align: left;\">A user-defined unique identifier representing a Subscriber<\/td>\n<td style=\"text-align: left;\"><code>M123456<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>listid<\/code><\/td>\n<td style=\"text-align: left;\">The corresponding list identifier of the Subscriber; returns the All Subscribers list id if the email is not sent to a specific list<\/td>\n<td style=\"text-align: left;\"><code>12345<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>list_<\/code><\/td>\n<td style=\"text-align: left;\">The <code>listid<\/code> value suffixed with an underscore character and the email type (either <code>TEXT<\/code> or <code>HTML<\/code>)<\/td>\n<td style=\"text-align: left;\"><code>12345_HTML<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>listsubid<\/code><\/td>\n<td style=\"text-align: left;\">A system-defined identifier representing the Subscriber&#8217;s relationship to the list<\/td>\n<td style=\"text-align: left;\"><code>987654321<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>_messagetypepreference<\/code><\/td>\n<td style=\"text-align: left;\">The Subscriber&#8217;s preferred email type, as defined as in the HTML Emails Attribute in the Subscriber record; either <code>TEXT<\/code> or <code>HTML<\/code><\/td>\n<td style=\"text-align: left;\"><code>HTML<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Sender Data Strings<\/h3>\n<table>\n<thead>\n<tr>\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"text-align: left;\"><code>replyname<\/code><\/td>\n<td style=\"text-align: left;\">The email From name, retrieved from the Sender Information in the Sender Profile, or the selected user profile<\/td>\n<td style=\"text-align: left;\"><code>Limedash Corporation<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>replyemailaddress<\/code><\/td>\n<td style=\"text-align: left;\">The email From email address, retrieved from the Sender Information in the Sender Profile, or the selected user profile<\/td>\n<td style=\"text-align: left;\"><code>marketing@email.limedash.com<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>memberid<\/code><\/td>\n<td style=\"text-align: left;\">The member identifier (MID) of the Business Unit which the email is sent from<\/td>\n<td style=\"text-align: left;\"><code>6541234<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>member_busname<\/code><\/td>\n<td style=\"text-align: left;\">The &quot;Company Name&quot; value defined for the Business Unit which the email is sent from<\/td>\n<td style=\"text-align: left;\"><code>Limedash Corporation, Inc<\/code>.<\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>member_addr<\/code><\/td>\n<td style=\"text-align: left;\">The &quot;Street Address&quot; value defined for the Business Unit which the email is sent from<\/td>\n<td style=\"text-align: left;\"><code>4463 Shinn Street<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>member_city<\/code><\/td>\n<td style=\"text-align: left;\">The &quot;City&quot; value defined for the Business Unit which the email is sent from<\/td>\n<td style=\"text-align: left;\"><code>New York<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>member_state<\/code><\/td>\n<td style=\"text-align: left;\">The &quot;State\/Province&quot; value defined for the Business Unit which the email is sent from<\/td>\n<td style=\"text-align: left;\"><code>NY<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>member_postalcode<\/code><\/td>\n<td style=\"text-align: left;\">The &quot;Zip\/Postal Code&quot; value defined for the Business Unit which the email is sent from<\/td>\n<td style=\"text-align: left;\"><code>10019<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>member_country<\/code><\/td>\n<td style=\"text-align: left;\">The &quot;Country&quot; value defined for the Business Unit which the email is sent from<\/td>\n<td style=\"text-align: left;\"><code>United States<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Email URL Data Strings<\/h3>\n<table>\n<thead>\n<tr>\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"text-align: left;\"><code>view_email_url<\/code><\/td>\n<td style=\"text-align: left;\">URL to view the email<\/td>\n<td style=\"text-align: left;\"><code>http:\/\/view.s6.exacttarget.com\/?qs=17f9ecc7fcd5...<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>ftaf_url<\/code><\/td>\n<td style=\"text-align: left;\">URL to a Forward to a Friend form page<\/td>\n<td style=\"text-align: left;\"><code>http:\/\/view.s6.exacttarget.com\/ftaf.aspx?qs=17f9ecce47fcd...<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>subscription_center_url<\/code><\/td>\n<td style=\"text-align: left;\">URL of the Subscriber&#8217;s Subscription Center<\/td>\n<td style=\"text-align: left;\"><code>http:\/\/cl.s6.exct.net\/subscription_center.aspx?qs=8ecce2c86ef063c...<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>profile_center_url<\/code><\/td>\n<td style=\"text-align: left;\">URL of the Subscriber&#8217;s Profile Center<\/td>\n<td style=\"text-align: left;\"><code>http:\/\/cl.s6.exct.net\/profile_center.aspx?qs=8ecce2c86ef063c31effc761<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>unsub_center_url<\/code><\/td>\n<td style=\"text-align: left;\">URL of the Subscriber&#8217;s One-Click Unsubscribe page<\/td>\n<td style=\"text-align: left;\"><code>http:\/\/cl.s6.exct.net\/unsub_center.aspx?qs=8ecce2c86ef063c3...<\/code><\/td>\n<\/tr>\n<tr>\n<td style=\"text-align: left;\"><code>double_opt_in_url<\/code><\/td>\n<td style=\"text-align: left;\">Inserts a double opt-in link in an email if this feature is enabled<\/td>\n<td style=\"text-align: left;\"><code>http:\/\/cl.exct.net\/sub_confirm.asp?lst=1234&amp;eml=...<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Reply Mail Management Strings<\/h3>\n<p>When Reply Mail Management (RMM) is enabled on an account, custom RMM settings can be configured in the sender profile to forward a Triggered Send email to a user or email address, or reply to the Subscriber using a Triggered Send email. This functionality is enabled by checking the &#8216;Forward using triggered send&#8217; or &#8216;Reply using triggered send&#8217; options in the sender profile.<\/p>\n<p>Triggered Send emails used for RMM forwarding or replies can contain personalization strings to extract information from the reply email. These personalization strings can be used with AMPscript to customize the email that is forwarded to a user or email address. Additionally, when the &#8216;Reply using triggered send&#8217; option is used, the Triggered Send email can include information from the Subscribers&#8217; original reply. Use cases for RMM forwarding and replies with Triggered Send emails include:<\/p>\n<ul>\n<li>Respond with an acknowledgment email to the Subscriber and a formatted abstract of their reply email, explaining they will receive a response in two business days<\/li>\n<li>Send the email to an internal email address and include details of the email that the Subscriber replied to (for example, the email name and related journey)<\/li>\n<li>Strip the original email from the reply email thread<\/li>\n<li>Log the email reply into a Data Extension<\/li>\n<li>Create Tasks or Activities in Sales Cloud from the email reply<\/li>\n<li>Identify keywords used in the reply message to conditionally trigger other platform actions<\/li>\n<\/ul>\n<div class=\"rcp_restricted rcp_paid_only\"><div>\n\n\n\t\n\t<form id=\"rcp_login_form\"  class=\"rcp_form\" method=\"POST\" action=\"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/\">\n\n\t\t\n\t\t<fieldset class=\"rcp_login_data\">\n\t\t\t<p>\n\t\t\t\t<label for=\"rcp_user_login\">Username or Email<\/label>\n\t\t\t\t<input name=\"rcp_user_login\" id=\"rcp_user_login\" class=\"required\" type=\"text\"\/>\n\t\t\t<\/p>\n\t\t\t<p>\n\t\t\t\t<label for=\"rcp_user_pass\">Password<\/label>\n\t\t\t\t<input name=\"rcp_user_pass\" id=\"rcp_user_pass\" class=\"required\" type=\"password\"\/>\n\t\t\t<\/p>\n\t\t\t\t\t\t<p>\n\t\t\t\t<input type=\"checkbox\" name=\"rcp_user_remember\" id=\"rcp_user_remember\" value=\"1\"\/>\n\t\t\t\t<label for=\"rcp_user_remember\">Remember me<\/label>\n\t\t\t<\/p>\n\t\t\t<p class=\"rcp_lost_password\"><a href=\"\/wp-json\/wp\/v2\/posts\/31346?rcp_action=lostpassword\">Lost your password?<\/a><\/p>\n\t\t\t<p>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_action\" value=\"login\"\/>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_redirect\" value=\"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/\"\/>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_login_nonce\" value=\"339584e63b\"\/>\n\t\t\t\t<input id=\"rcp_login_submit\" class=\"rcp-button\" type=\"submit\" value=\"Login\"\/>\n\t\t\t<\/p>\n\t\t\t\t\t<\/fieldset>\n\n\t\t\n\t<\/form>\n<br \/>\nNot a subscriber? <a href=\"\/subscriptions\/subscribe\/\">Subscribe now<\/a>.\n<\/div>\n<\/div>\n<h3>MobileConnect Data Strings<\/h3>\n<p>MobileConnect messages use <em>nouns<\/em> and <em>verbs<\/em>. A verb is a keyword used in a Mobile Originated (MO) message. Nouns are strings that appear after the keyword. In the example below, <code>OFFER<\/code> is the keyword, or verb, of the message and <code>Curt Harris<\/code> forms the message nouns.<\/p>\n<pre><code>OFFER Curt Harris<\/code><\/pre>\n<table>\n<colgroup>\n<col style=\"width: 16%\">\n<col style=\"width: 48%\">\n<col style=\"width: 35%\">\n<\/colgroup>\n<thead>\n<tr class=\"header\">\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>MOBILE_NUMBER<\/code><\/td>\n<td style=\"text-align: left;\">The mobile number of the Contact, prefixed with an area code<\/td>\n<td style=\"text-align: left;\"><code>17182097651<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>SHORT_CODE<\/code><\/td>\n<td style=\"text-align: left;\">The associated short or long code used to send the message<\/td>\n<td style=\"text-align: left;\">\n<code>111322<\/code> (<em>short code<\/em>) or <code>19172759833<\/code> (<em>long code<\/em>)<\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>MSG(0)<\/code><\/td>\n<td style=\"text-align: left;\">The entire message<\/td>\n<td style=\"text-align: left;\"><code>OFFER Curt Harris<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>MSG(0).VERB<\/code><\/td>\n<td style=\"text-align: left;\">The message keyword<\/td>\n<td style=\"text-align: left;\"><code>OFFER<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>MSG(0).NOUNS<\/code><\/td>\n<td style=\"text-align: left;\">The part of the message after the verb<\/td>\n<td style=\"text-align: left;\"><code>Curt Harris<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>MSG(0).NOUN([n])<\/code><\/td>\n<td style=\"text-align: left;\">Returns the &#8216;n&#8217; noun in the current message using a zero-based index, (<code>0<\/code> returns the first noun, <code>1<\/code> returns the second noun etc.)<\/td>\n<td style=\"text-align: left;\">\n<code>MSG(0).NOUN(0)<\/code> = <code>Curt<\/code>\n<\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>MMS_CONTENT_URL([n])<\/code><\/td>\n<td style=\"text-align: left;\">Similar to <code>MSG(0)<\/code> but used for MMS messages. Returns the URL of the MMS content from the incoming MO message, where &#8216;n&#8217; is the zero-based index of the MMS content contained in the MO message. A value of <code>0<\/code> indicates the MMS content in the current MO message.<\/td>\n<td style=\"text-align: left;\"><code>http:\/\/exacttarget.com\/mms.aspx?qs=17f9ecce47fcd<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Example<\/h4>\n<p>This example code is used in a text response template and inserts the message into a Data Extension when a Contact replies to a text response message.<br \/>\n<div class=\"rcp_restricted rcp_paid_only\"><div>\n\n\n\t\n\t<form id=\"rcp_login_form\"  class=\"rcp_form\" method=\"POST\" action=\"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/\">\n\n\t\t\n\t\t<fieldset class=\"rcp_login_data\">\n\t\t\t<p>\n\t\t\t\t<label for=\"rcp_user_login\">Username or Email<\/label>\n\t\t\t\t<input name=\"rcp_user_login\" id=\"rcp_user_login\" class=\"required\" type=\"text\"\/>\n\t\t\t<\/p>\n\t\t\t<p>\n\t\t\t\t<label for=\"rcp_user_pass\">Password<\/label>\n\t\t\t\t<input name=\"rcp_user_pass\" id=\"rcp_user_pass\" class=\"required\" type=\"password\"\/>\n\t\t\t<\/p>\n\t\t\t\t\t\t<p>\n\t\t\t\t<input type=\"checkbox\" name=\"rcp_user_remember\" id=\"rcp_user_remember\" value=\"1\"\/>\n\t\t\t\t<label for=\"rcp_user_remember\">Remember me<\/label>\n\t\t\t<\/p>\n\t\t\t<p class=\"rcp_lost_password\"><a href=\"\/wp-json\/wp\/v2\/posts\/31346?rcp_action=lostpassword\">Lost your password?<\/a><\/p>\n\t\t\t<p>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_action\" value=\"login\"\/>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_redirect\" value=\"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/\"\/>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_login_nonce\" value=\"339584e63b\"\/>\n\t\t\t\t<input id=\"rcp_login_submit\" class=\"rcp-button\" type=\"submit\" value=\"Login\"\/>\n\t\t\t<\/p>\n\t\t\t\t\t<\/fieldset>\n\n\t\t\n\t<\/form>\n<br \/>\nNot a subscriber? <a href=\"\/subscriptions\/subscribe\/\">Subscribe now<\/a>.\n<\/div>\n<\/div><\/p>\n<h3>MobileConnect Contact Data Strings<\/h3>\n<p>The following personalization strings represent the MobileConnect Demographic data for a mobile subscriber in Marketing Cloud.<\/p>\n<table>\n<colgroup>\n<col style=\"width: 13%\">\n<col style=\"width: 53%\">\n<col style=\"width: 33%\">\n<\/colgroup>\n<thead>\n<tr class=\"header\">\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_CarrierID<\/code><\/td>\n<td style=\"text-align: left;\">Carrier ID<\/td>\n<td style=\"text-align: left;\"><code>4<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_Channel<\/code><\/td>\n<td style=\"text-align: left;\">Channel<\/td>\n<td style=\"text-align: left;\"><code>Mobile<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_City<\/code><\/td>\n<td style=\"text-align: left;\">City<\/td>\n<td style=\"text-align: left;\"><code>Overland Park<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_ContactID<\/code><\/td>\n<td style=\"text-align: left;\">Contact ID<\/td>\n<td style=\"text-align: left;\"><code>13197985<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_CountryCode<\/code><\/td>\n<td style=\"text-align: left;\">Country code<\/td>\n<td style=\"text-align: left;\"><code>US<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_CreatedBy<\/code><\/td>\n<td style=\"text-align: left;\">The ID of the entity that created the Contact<\/td>\n<td style=\"text-align: left;\"><code>6387679<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_CreatedDate<\/code><\/td>\n<td style=\"text-align: left;\">Date the Contact was created<\/td>\n<td style=\"text-align: left;\"><code>2018-10-01 13:33<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_FirstName<\/code><\/td>\n<td style=\"text-align: left;\">First name<\/td>\n<td style=\"text-align: left;\"><code>Nora<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_IsHonorDST<\/code><\/td>\n<td style=\"text-align: left;\">Contact\u2019s time zone honors Daylight Savings Time<\/td>\n<td style=\"text-align: left;\">\n<code>True<\/code> or <code>False<\/code>\n<\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_LastName<\/code><\/td>\n<td style=\"text-align: left;\">Last name<\/td>\n<td style=\"text-align: left;\"><code>Taylor<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_MobileNumber<\/code><\/td>\n<td style=\"text-align: left;\">Mobile number<\/td>\n<td style=\"text-align: left;\"><code>19135551212<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_ModifiedBy<\/code><\/td>\n<td style=\"text-align: left;\">ID of the entity that last modified the Contact<\/td>\n<td style=\"text-align: left;\"><code>6387679<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_ModifiedDate<\/code><\/td>\n<td style=\"text-align: left;\">Date and time the Contact data was last modified<\/td>\n<td style=\"text-align: left;\"><code>2018-10-02 12:22<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_Priority<\/code><\/td>\n<td style=\"text-align: left;\">Priority to use when sending a message to the Contact<\/td>\n<td style=\"text-align: left;\"><code>1<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_Source<\/code><\/td>\n<td style=\"text-align: left;\">Source of Contact information<\/td>\n<td style=\"text-align: left;\"><code>Mobile Opt-in<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_SourceObjectID<\/code><\/td>\n<td style=\"text-align: left;\">Internal unique ID of the Contact\u2019s source<\/td>\n<td style=\"text-align: left;\"><code>2<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_State<\/code><\/td>\n<td style=\"text-align: left;\">State associated with the Contact<\/td>\n<td style=\"text-align: left;\"><code>KS<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_Status<\/code><\/td>\n<td style=\"text-align: left;\">Send status of the Contact<\/td>\n<td style=\"text-align: left;\">\n<ul>\n<li>\n<code>-1<\/code> &#8211; Unspecified<\/li>\n<li>\n<code> 1<\/code> &#8211; Active<\/li>\n<li>\n<code> 2<\/code> &#8211; Bounced<\/li>\n<li>\n<code> 3<\/code> &#8211; Held<\/li>\n<li>\n<code> 4<\/code> &#8211; Unsubscribed<\/li>\n<\/ul>\n<\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_UTCOffset<\/code><\/td>\n<td style=\"text-align: left;\">Number of hours from which the Contact\u2019s time zone deviates from UTC<\/td>\n<td style=\"text-align: left;\"><code>-6<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_ZipCode<\/code><\/td>\n<td style=\"text-align: left;\">Zip code associated with the Contact<\/td>\n<td style=\"text-align: left;\"><code>55555<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<blockquote>\n<p>NOTE: <em>CarrierID<\/em> field values are reportedly incorrect or inconsistent.  Use with caution.<\/p>\n<\/blockquote>\n<div class=\"rcp_restricted rcp_paid_only\"><div>\n\n\n\t\n\t<form id=\"rcp_login_form\"  class=\"rcp_form\" method=\"POST\" action=\"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/\">\n\n\t\t\n\t\t<fieldset class=\"rcp_login_data\">\n\t\t\t<p>\n\t\t\t\t<label for=\"rcp_user_login\">Username or Email<\/label>\n\t\t\t\t<input name=\"rcp_user_login\" id=\"rcp_user_login\" class=\"required\" type=\"text\"\/>\n\t\t\t<\/p>\n\t\t\t<p>\n\t\t\t\t<label for=\"rcp_user_pass\">Password<\/label>\n\t\t\t\t<input name=\"rcp_user_pass\" id=\"rcp_user_pass\" class=\"required\" type=\"password\"\/>\n\t\t\t<\/p>\n\t\t\t\t\t\t<p>\n\t\t\t\t<input type=\"checkbox\" name=\"rcp_user_remember\" id=\"rcp_user_remember\" value=\"1\"\/>\n\t\t\t\t<label for=\"rcp_user_remember\">Remember me<\/label>\n\t\t\t<\/p>\n\t\t\t<p class=\"rcp_lost_password\"><a href=\"\/wp-json\/wp\/v2\/posts\/31346?rcp_action=lostpassword\">Lost your password?<\/a><\/p>\n\t\t\t<p>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_action\" value=\"login\"\/>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_redirect\" value=\"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/\"\/>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_login_nonce\" value=\"339584e63b\"\/>\n\t\t\t\t<input id=\"rcp_login_submit\" class=\"rcp-button\" type=\"submit\" value=\"Login\"\/>\n\t\t\t<\/p>\n\t\t\t\t\t<\/fieldset>\n\n\t\t\n\t<\/form>\n<br \/>\nNot a subscriber? <a href=\"\/subscriptions\/subscribe\/\">Subscribe now<\/a>.\n<\/div>\n<\/div>\n<h3>GroupConnect Data Strings<\/h3>\n<p>The following strings apply only to GroupConnect messages and cannot be used in other Marketing Cloud applications. Some strings are specific to integration with the <a href=\"https:\/\/line.me\/en\/\">LINE<\/a> messaging application.<\/p>\n<table>\n<colgroup>\n<col style=\"width: 15%\">\n<col style=\"width: 60%\">\n<col style=\"width: 24%\">\n<\/colgroup>\n<thead>\n<tr class=\"header\">\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>LINE_ADDRESS_ID<\/code><\/td>\n<td style=\"text-align: left;\">Unique LINE ID of a person<\/td>\n<td style=\"text-align: left;\"><code>eliotharper<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>LINE_JOB_ID<\/code><\/td>\n<td style=\"text-align: left;\">Unique LINE job identifier<\/td>\n<td style=\"text-align: left;\"><code>b409facab49447eb8f1d489e5473bf5e<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>LINE_SUBSCRIBER_ID<\/code><\/td>\n<td style=\"text-align: left;\">Corresponding Subscriber identifier in Marketing Cloud<\/td>\n<td style=\"text-align: left;\"><code>8765432<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>TEXT<\/code><\/td>\n<td style=\"text-align: left;\">The entire message<\/td>\n<td style=\"text-align: left;\"><code>OFFER Lily Baker<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>VERB<\/code><\/td>\n<td style=\"text-align: left;\">The first word in the message<\/td>\n<td style=\"text-align: left;\"><code>OFFER<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>TEXT.NOUN<\/code><\/td>\n<td style=\"text-align: left;\">All words after the verb<\/td>\n<td style=\"text-align: left;\"><code>Lily Baker<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>TEXT.NOUN([n])<\/code><\/td>\n<td style=\"text-align: left;\">Returns the &#8216;n&#8217; noun in the current message using a zero-based index, (<code>0<\/code> returns the first noun, <code>1<\/code> returns the second noun etc.)<\/td>\n<td style=\"text-align: left;\">\n<code>MSG(0).NOUN(0)<\/code> = Lily<\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>STKR.STKPKGID<\/code><\/td>\n<td style=\"text-align: left;\">Package ID associated with the specified sticker (for LINE messages containing a sticker)<\/td>\n<td style=\"text-align: left;\"><code>1234<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>STKR.STKID<\/code><\/td>\n<td style=\"text-align: left;\">ID associated with the specified sticker (for LINE messages containing a sticker)<\/td>\n<td style=\"text-align: left;\"><code>5678<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>STKR.STKTXT<\/code><\/td>\n<td style=\"text-align: left;\">Text associated with the specified sticker (for LINE messages containing a sticker)<\/td>\n<td style=\"text-align: left;\"><code>happy<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Website Data Strings<\/h3>\n<p>The following strings apply only to landing pages, microsites and CloudPages and cannot be used in other Marketing Cloud applications.<\/p>\n<table>\n<colgroup>\n<col style=\"width: 24%\">\n<col style=\"width: 40%\">\n<col style=\"width: 35%\">\n<\/colgroup>\n<thead>\n<tr class=\"header\">\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>microsite_base_url[default]ID[\/default]<\/code><\/td>\n<td style=\"text-align: left;\">URL to a microsite landing page. Replace <code>ID<\/code> with the unique ID value for the landing page. This string is for classic landing pages and does not function in CloudPages.<\/td>\n<td style=\"text-align: left;\"><code>https:\/\/pub.s1.exacttarget.com\/page.aspx?qs=1550dccf35ce...<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>PAGEURL<\/code><\/td>\n<td style=\"text-align: left;\">URL of current landing page with URL parameters<\/td>\n<td style=\"text-align: left;\"><code>https:\/\/pub.s1.exacttarget.com\/lcuh4w3abc?subscriber=12345<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Email Analytics Strings<\/h3>\n<table>\n<colgroup>\n<col style=\"width: 19%\">\n<col style=\"width: 71%\">\n<col style=\"width: 9%\">\n<\/colgroup>\n<thead>\n<tr class=\"header\">\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>linkname<\/code><\/td>\n<td style=\"text-align: left;\">The value entered in the <code>alias<\/code> link attribute. If no value is specified, it contains the complete URL.<\/td>\n<td style=\"text-align: left;\"><code>CTA<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>_ImpressionRegionID<\/code><\/td>\n<td style=\"text-align: left;\">Returns the ID of the Impression Region. Contains <code>0<\/code> if there are no active Impression Regions.<\/td>\n<td style=\"text-align: left;\"><code>1<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>_ImpressionRegionName<\/code><\/td>\n<td style=\"text-align: left;\">Returns the name of the active Impression Region defined in the email.<\/td>\n<td style=\"text-align: left;\"><code>heading<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>AdditionalInfo_<\/code><\/td>\n<td style=\"text-align: left;\">The value entered into the Additional Info field when sending an email. This value is appended to email links as a URL parameter. This feature requires the <a href=\"https:\/\/help.salesforce.com\/s\/articleView?id=sf.mc_overview_parameter_management.htm&amp;type=5\">Parameter Manager<\/a> to be enabled in Setup.<\/td>\n<td style=\"text-align: left;\"><code>summeroffer<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>__AdditionalEmailAttribute[n]<\/code><\/td>\n<td style=\"text-align: left;\">The values entered into the Additional Email Attributes fields when sending an email, where <code>[n]<\/code> is an integer from 1 to 5 (up to five Additional Email Attributes are supported). These values are appended to email links as a URL parameter. This feature requires the <a href=\"https:\/\/help.salesforce.com\/s\/articleView?id=sf.mc_overview_parameter_management.htm&amp;type=5\">Parameter Manager<\/a> to be enabled in Setup.<\/td>\n<td style=\"text-align: left;\"><code>segment1<\/code><\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3>Einstein Email Data Strings<\/h3>\n<p>The following strings can be used for formatting and sanitizing Einstein Email Recommendation data. These strings differ from other system personalization strings in that they behave similar to a function, where the string value is interpreted based on arguments within the string construct.<\/p>\n<table>\n<colgroup>\n<col style=\"width: 13%\">\n<col style=\"width: 55%\">\n<col style=\"width: 31%\">\n<\/colgroup>\n<thead>\n<tr class=\"header\">\n<th style=\"text-align: left;\">String<\/th>\n<th style=\"text-align: left;\">Description<\/th>\n<th style=\"text-align: left;\">Example Output<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>ImageLink<\/code><\/td>\n<td style=\"text-align: left;\">Value of the &#8216;Image URL&#8217; mapped field in the product catalog<\/td>\n<td style=\"text-align: left;\"><code>https:\/\/limedash.com\/products\/1000100.jpg<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>ProductName<\/code><\/td>\n<td style=\"text-align: left;\">Value of the &#8216;Product&#8217; mapped field in the product catalog<\/td>\n<td style=\"text-align: left;\"><code>Apex Bionic Jacket<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>Description<\/code><\/td>\n<td style=\"text-align: left;\">Value of the &#8216;Product Description&#8217; mapped field in the product catalog<\/td>\n<td style=\"text-align: left;\"><code>This coveted soft shell keeps you warm and windchill-free.<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>RegularPrice<\/code><\/td>\n<td style=\"text-align: left;\">Value of the &#8216;Regular Price&#8217; mapped field in the product catalog<\/td>\n<td style=\"text-align: left;\"><code>16.99<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>SalePrice<\/code><\/td>\n<td style=\"text-align: left;\">Value of the &#8216;Sale Price&#8217; mapped field in the product catalog<\/td>\n<td style=\"text-align: left;\"><code>12.99<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>RegularPriceMain<\/code><\/td>\n<td style=\"text-align: left;\">Outputs the integer part (before the decimal) of the field mapped to <code>RegularPrice<\/code> or <code>Price<\/code> for streaming updates<\/td>\n<td style=\"text-align: left;\"><code>65<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>SalePriceMain<\/code><\/td>\n<td style=\"text-align: left;\">Outputs the integer part (before the decimal) of the field mapped to <code>SalePrice<\/code>\n<\/td>\n<td style=\"text-align: left;\"><code>42<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>RegularPriceFractional<\/code><\/td>\n<td style=\"text-align: left;\">Outputs the fractional part (integer after the decimal) of the field mapped to <code>RegularPrice<\/code> or <code>Price<\/code> for streaming updates<\/td>\n<td style=\"text-align: left;\"><code>99<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>SalePriceFractional<\/code><\/td>\n<td style=\"text-align: left;\">Outputs the fractional part (integer after the decimal) of the field mapped to <code>SalePrice<\/code> for streaming updates<\/td>\n<td style=\"text-align: left;\"><code>50<\/code><\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>ToFloat<\/code><\/td>\n<td style=\"text-align: left;\">Converts the value of a string field in a Catalog to a floating-point number<\/td>\n<td style=\"text-align: left;\"><code>12.25<\/code><\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>[a]LongestWordLength<\/code><\/td>\n<td style=\"text-align: left;\">Calculates the longest word in an attribute and outputs the length of that word as a number, where <code>[a]<\/code> is the attribute<\/td>\n<td style=\"text-align: left;\">For a Description attribute with the string &#8216;Also available in black&#8217; , <code>%%DescriptionLongestWordLength%%<\/code> will output <code>9<\/code>.<\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>[a]LengthNum<\/code><\/td>\n<td style=\"text-align: left;\">Returns the length of a Catalog attribute, where <code>[a]<\/code> is the attribute<\/td>\n<td style=\"text-align: left;\">For a Description with the string &#8216;One size only&#8217;, <code>%%DescriptionLengthNum%%<\/code> will output <code>13<\/code>.<\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>First[n]<\/code><\/td>\n<td style=\"text-align: left;\">Outputs the first characters of value, where <code>[n]<\/code> is an integer<\/td>\n<td style=\"text-align: left;\">\n<code>%%SKUFirst5%%<\/code> will output <code>ABC123<\/code>\n<\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>Split[d]At[i]<\/code><\/td>\n<td style=\"text-align: left;\">Splits a value and returns the given index, where <code>[d]<\/code> is the delimiter and <code>[i]<\/code> is a zero-based index. The delimiter can be longer than one character and the index can be negative.<\/td>\n<td style=\"text-align: left;\">For a Size attribute with the string &#8216;small;medium;large&#8217; , <code>%%Split;At1%%<\/code> will output <code>medium<\/code>.<\/td>\n<\/tr>\n<tr class=\"odd\">\n<td style=\"text-align: left;\"><code>[a]Replace[r]With[w]End<\/code><\/td>\n<td style=\"text-align: left;\">Globally replaces a given string with another string from a Catalog attribute, where <code>[a]<\/code> is the attribute, <code>[r]<\/code> is the string to match and <code>[w]<\/code> is the string to replace<\/td>\n<td style=\"text-align: left;\">For a Color attribute with the string &#8216;Purple&#8217;, <code>%%ColorReplacePurpleWithLavenderEnd%%<\/code> will output <code>Lavender<\/code>.<\/td>\n<\/tr>\n<tr class=\"even\">\n<td style=\"text-align: left;\"><code>[a]UpTo[n]By[d]With[o]End<\/code><\/td>\n<td style=\"text-align: left;\">Outputs the value of a Catalog attribute up to an index with an appended string (if included), where <code>[a]<\/code> is the attribute, <code>[i]<\/code> is a whole number of characters to evaluate, <code>[d]<\/code> is the delimiter and <code>[o]<\/code> is the optional string into append. Values shorter than the limit output unaltered and values without a delimiter that match within the limit output blank.<\/td>\n<td style=\"text-align: left;\">For a Size attribute with the string &#8216;small;medium;large&#8217;, <code>%%SizeUpTo14By;With~End%%<\/code> will output <code>small;medium~<\/code>.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h4>Chaining<\/h4>\n<p>When using Einstein Email Data Strings, strings can be chained together into a single string. The example below illustrates that for a <code>ProductName<\/code> attribute with a value <code>Vintage Cruiser Bike<\/code>, <code>Vintage<\/code> is changed to <code>Classic<\/code> and the product name is displayed in uppercase.<\/p>\n<div class=\"rcp_restricted rcp_paid_only\"><div>\n\n\n\t\n\t<form id=\"rcp_login_form\"  class=\"rcp_form\" method=\"POST\" action=\"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/\">\n\n\t\t\n\t\t<fieldset class=\"rcp_login_data\">\n\t\t\t<p>\n\t\t\t\t<label for=\"rcp_user_login\">Username or Email<\/label>\n\t\t\t\t<input name=\"rcp_user_login\" id=\"rcp_user_login\" class=\"required\" type=\"text\"\/>\n\t\t\t<\/p>\n\t\t\t<p>\n\t\t\t\t<label for=\"rcp_user_pass\">Password<\/label>\n\t\t\t\t<input name=\"rcp_user_pass\" id=\"rcp_user_pass\" class=\"required\" type=\"password\"\/>\n\t\t\t<\/p>\n\t\t\t\t\t\t<p>\n\t\t\t\t<input type=\"checkbox\" name=\"rcp_user_remember\" id=\"rcp_user_remember\" value=\"1\"\/>\n\t\t\t\t<label for=\"rcp_user_remember\">Remember me<\/label>\n\t\t\t<\/p>\n\t\t\t<p class=\"rcp_lost_password\"><a href=\"\/wp-json\/wp\/v2\/posts\/31346?rcp_action=lostpassword\">Lost your password?<\/a><\/p>\n\t\t\t<p>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_action\" value=\"login\"\/>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_redirect\" value=\"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/\"\/>\n\t\t\t\t<input type=\"hidden\" name=\"rcp_login_nonce\" value=\"339584e63b\"\/>\n\t\t\t\t<input id=\"rcp_login_submit\" class=\"rcp-button\" type=\"submit\" value=\"Login\"\/>\n\t\t\t<\/p>\n\t\t\t\t\t<\/fieldset>\n\n\t\t\n\t<\/form>\n<br \/>\nNot a subscriber? <a href=\"\/subscriptions\/subscribe\/\">Subscribe now<\/a>.\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>System Strings Marketing Cloud includes a library of system-based personalization strings which can be included in a message or on a page to output a value, based on the context of the Subscriber, Contact or a message. Email Date Strings NOTE: Date-based personalization strings use the system time (the data center location of your Marketing [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v14.7 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>The AMPscript Guide - System Strings<\/title>\n<meta name=\"robots\" content=\"index, follow\" \/>\n<meta name=\"googlebot\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta name=\"bingbot\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/ampscript.guide\/system-strings\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"The AMPscript Guide - System Strings\" \/>\n<meta property=\"og:description\" content=\"System Strings Marketing Cloud includes a library of system-based personalization strings which can be included in a message or on a page to output a value, based on the context of the Subscriber, Contact or a message. Email Date Strings NOTE: Date-based personalization strings use the system time (the data center location of your Marketing [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/ampscript.guide\/system-strings\/\" \/>\n<meta property=\"og:site_name\" content=\"The AMPscript Guide\" \/>\n<meta property=\"article:published_time\" content=\"2018-04-21T15:47:45+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-07-26T16:25:56+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/ampscript.guide\/#website\",\"url\":\"https:\/\/ampscript.guide\/\",\"name\":\"The AMPscript Guide\",\"description\":\"The Definitive Scripting Manual for Salesforce Marketing Cloud\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":\"https:\/\/ampscript.guide\/?s={search_term_string}\",\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ampscript.guide\/system-strings\/#webpage\",\"url\":\"https:\/\/ampscript.guide\/system-strings\/\",\"name\":\"The AMPscript Guide - System Strings\",\"isPartOf\":{\"@id\":\"https:\/\/ampscript.guide\/#website\"},\"datePublished\":\"2018-04-21T15:47:45+00:00\",\"dateModified\":\"2022-07-26T16:25:56+00:00\",\"author\":{\"@id\":\"https:\/\/ampscript.guide\/#\/schema\/person\/5335042f77731e84f9808aecef25daec\"},\"breadcrumb\":{\"@id\":\"https:\/\/ampscript.guide\/system-strings\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/ampscript.guide\/system-strings\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/ampscript.guide\/system-strings\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"item\":{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ampscript.guide\/\",\"url\":\"https:\/\/ampscript.guide\/\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"position\":2,\"item\":{\"@type\":\"WebPage\",\"@id\":\"https:\/\/ampscript.guide\/system-strings\/\",\"url\":\"https:\/\/ampscript.guide\/system-strings\/\",\"name\":\"System Strings\"}}]},{\"@type\":[\"Person\"],\"@id\":\"https:\/\/ampscript.guide\/#\/schema\/person\/5335042f77731e84f9808aecef25daec\",\"name\":\"dev\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","_links":{"self":[{"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346"}],"collection":[{"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/comments?post=31346"}],"version-history":[{"count":0,"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/posts\/31346\/revisions"}],"wp:attachment":[{"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/media?parent=31346"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/categories?post=31346"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/ampscript.guide\/wp-json\/wp\/v2\/tags?post=31346"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}