Keyword Replacements

Last Updated: 24 Oct 2017

This chapter outlines the keyword replacements that can be used on a Custom Form within Squiz Matrix.

Bookmarks

Custom Form

The following keyword replacements can be used on the Custom Form.

Email Options Screen - Recipient Email Option

The keyword replacements listed below allow you to display the responses the users entered to the question on the Custom Form. For a full list of available keyword replacements, click on the hyperlink available on the Email Options screen of the Custom Form.

Keyword Replacement Information shown
%form_info% This will show information about the Custom Form including its asset ID, name and URL of the form and the name and asset ID of the site.
%form_summary% The summary of all responses that the user entered on the form.
%section_summary_{section_asset_id}% The summary of a specific form section.

Email Options Screen - Receipt Email Option

The keyword replacements listed below allow you to display the responses the users entered to the question on the Custom Form. For a full list of keyword replacements, click on the hyperlink available on the Email Options screen of the Custom Form.

Keyword Replacement Information shown
%form_info% This will show information about the Custom Form including its asset ID, name and URL of the form and the name and asset ID of the site.
%form_summary% The summary of all responses that the user entered on the form.
%section_summary_{section_asset_id}% The summary of a specific form section.

Email Options Screen - Send To A Friend Email Option

The keyword replacements listed below allow you to display the responses the users entered to the question on the Custom Form. For a full list of keyword replacements, click on the hyperlink available on the Email Options screen of the Custom Form.

Keyword Replacement Information shown
%form_info% This will show information about the Custom Form including its asset ID, name and URL of the form and the name and asset ID of the site.
%form_summary% This will show the responses that the user entered on the form.
%section_summary_{section_asset_id}% The summary of a specific form section.
%referral_url% This will add the URL of the last page that the user was viewing before they viewed the Custom Form.
%referring_asset_<keywordreplacement>% You can use keyword replacements from the referring asset by appending the normal asset keyword replacement onto the end of the %referring_asset_. For example, if you want to show the name of the referring asset, use the keyword replacement,%referring_asset_attribute_name%. The referral asset is the last page the user was viewing before they viewed the Custom Form.

Email Options Screen - Reminder Email Option

The keyword replacements listed below allow you to display information about the incomplete form and the direct the user back to complete it.

Keyword Replacement Information shown
%form_total_pages% This will show information about the Custom Form including its asset ID, name and URL of the form and the name and asset ID of the site.
%return_to_form_url_current% This will show the responses that the user entered on the form.
%return_to_form_url_latest% This will add the URL of the last page that the user was viewing before they viewed the Custom Form.
%user_asset_<keyword_replacement>% You can use keyword replacements from the user asset by appending the normal asset keyword replacement onto the end of %user_asset_.
%form_asset_<keyword_replacement>% You can use keyword replacements from the form asset by appending the normal asset keyword replacement onto the end of %form_asset_.
%submission_asset_<keyword_replacement>% You can use keyword replacements from the submission asset by appending the normal asset keyword replacement onto the end of %submission_asset_. For example, if you want to show the ID of the submission asset, use the keyword %submission_asset_assetid%.

Page Contents Bodycopy

The keyword replacements listed below allow you to layout each question individually. For a full list of these keyword replacements, refer to the select keyword list in the WYSIWYG Editor.

Keyword Replacement Information shown
%form_contents% This will display the default layout of the questions and sections fields, as configured in the Page Contents Bodycopy.

This keyword is useful if you are not individually formatting the layout of each section and/or question on the Custom Form.
%current_page_contents% This will show the questions as they appear on the default layout, for an individual page.
 
This keyword essentially replaces the %form_contents% keyword when dealing with a Custom Form that utilizes the Multi-Page feature.
%form_errors% This will show any errors the user may have received when they click the submit button. On the default layout these errors appear at the bottom of the page. When using the Page Contents Bodycopy you may want to show them at the top of the page.
 
Please note that when the Accessible Format option is enabled, form question and CAPTCHA errors will be displayed next to their corresponding fields. General form errors, however, will continue to be displayed on this keyword.
%form_errors_message% This will show the message that has been defined in the Error Message Format field on the Form Contents screen. By default, this message is 'There were errors submitting the form. Please correct the marked fields and try again'.
%reset_button% This will show the reset button on the form. This button is not mandatory.
%submit_button% This will show the submit button on the form. If you do not add this keyword replacement the user will not be able to submit the form. When the Multi-Page feature is utilized, the submit button will convert to the next page button on all but the final page of the Custom Form.
%previous_page_button% This will show the previous page button on the form. This button is only compatible when dealing with a Custom Form that utilizes the Multi-Page feature. The previous page button will automatically not appear on the first page of the form.
%save_button% This will show the save button on the form. This button is not mandatory.
%save_and_exit_button% This will show the save and exit button on the form. This button is not mandatory.
%form_captcha% This will show the CAPTCHA fields on the form.
%form_captcha_image% This will show the image for the CAPTCHA field.
%form_captcha_field% This will show the input field for the CAPTCHA field.
%form_captcha_link% This will show the link so the user can regenerate the CAPTCHA field.
%form_mollom_captcha%  This will display the Mollom CAPTCHA fields on the form. This includes the CAPTCHA image, input field and regeneration link.
%form_mollom_captcha_image%   This will display the Mollom image CAPTCHA field.
%form_mollom_captcha_audio%  This will display the Mollom audio CAPTCHA field.
%form_mollom_captcha_field% This will display the input field for the Mollom CAPTCHA.
%form_mollom_captcha_link% This will display the link for users to regenerate the image and/or audio CAPTCHA fields.
%form_recaptcha%  This will display the Google reCAPTCHA fields.
%form_honeypot_field%  This will display the configured honeypot question field.
%section_title_<parent_id>% This will show the name of a Section where <parent_id> is the asset ID of the Section.
%section_title% The name of the section when used in the customised Bodycopy of a Section.
%section_contents_<parent_id>% The questions in a particular Section, as they appear on the default layout. If you do not want to layout each question in a section individually, use this keyword replacement. Otherwise use the keyword replacements provided to layout each question individually.
%section_contents% The name and the contents of each question of the Section when used in the customised Bodycopy of a Section.
%section_questions_contents_<parent_id>% The contents of each question of a Section where <parent_id> is the asset ID of the Section.
%section_questions_contents% The contents of each question of the section when used in the customised Bodycopy of a Section.
%question_label_<parent_id>_<question_id>% This will show the label of the question where <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_name_<parent_id>_<question_id>% This will show the name of the question where <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_note_<parent_id>_<question_id>% This will show the note for the question where <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_id_<parent_id>_<question_id>% This will show the asset ID of the question where <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_field_<parent_id>_<question_id>% This will show the input field where the user can enter their response to the question. <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_contents_<parent_id>_<question_id>% This will show the input field and label of the question. <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%page_list% This will show a list of the pages of the form, when dealing with a Custom Form that utilizes the Multi-Page feature. The Page List's appearance can be customised on the Form Contents screen.

Confirmation Page Contents Layout

The keyword replacements listed below allow you to display the responses to the questions the user submitted on the form, to allow the user to confirm their submission. For a full list of these keyword replacements, refer to the select keyword list in the WYSIWYG Editor.

Keyword Replacement Information shown
%form_summary% This will show the responses that the user entered to each question on the form in a table layout.
%form_summary_semantic% This prints the summary of the form submissions in a definition list.
%section_summary_{section_asset_id}% The summary of a specific form section printed in a table layout.
%section_summary_semantic_{section_asset_id}% The summary of a specific form section printed in a definition list.
%form_info% This will show information about the Custom Form including the asset ID, name and URL of the form, and the name and asset ID of the site.
%reset_button% This will show the reset button on the form. This button is not mandatory.
%submit_button% This will show the submit button on the form. If you do not add this keyword replacement the user will not be able to submit the form.
%form_captcha% This will show the CAPTCHA fields on the form.
%form_captcha_image% This will show the image for the CAPTCHA field.
%form_captcha_field% This will show the input field for the CAPTCHA field.
%form_captcha_link% This will show the link so the user can regenerate the CAPTCHA field.
%section_title_<parent_id>% This will show the name of the section. <parent_id> is the asset ID of the Section.
%section_contents_<parent_id>% This will show the questions in a particular section, as they appear on the default layout. If you do not want to layout each question in a section individually, use this keyword replacement. Otherwise use the keyword replacements provided to layout each question individually.
%question_label_<parent_id>_<question_id>% This will show the label of the question. <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_name_<parent_id>_<question_id>% This will show the name of the question. <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_note_<parent_id>_<question_id>% This will show the note for the question. <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_id_<parent_id>_<question_id>% This will show the asset ID of the question. <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%question_field_<parent_id>_<question_id>% This will show the box where the user can enter their response to the question. <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question. 

Thank You Bodycopy

The keyword replacements listed below allow you to display the responses to the questions the user submitted on the form. For a full list of these keyword replacements, refer to the select keyword list in the WYSIWYG Editor.

Keyword Replacement Information shown
%form_summary% This will show the responses that the user entered to each question on the form.
%form_summary_semantic% This prints the summary of the form submissions in a definition list.
%section_summary_{section_asset_id}% The summary of a specific form section.
%section_summary_semantic_{section_asset_id}% The summary of a specific form section printed in a definition list.
%form_info% This will show information about the Custom Form including the asset ID, name and URL of the form, and the name and asset ID of the site.
%form_submission_id% This will show the ID that the submission has been given.
%form_submission_ip_address% This will show the IP address of where the submission was made.
%form_submission_time% This will show the date and time the user submitted the form in the format yyyy-mm-dd hh:mm:ss.
%form_submission_time_short% This will show the date the user submitted the form in the format yyyy-mm-dd.
%form_submission_time_readable% This will show the date and time the user submitted the form in the format ss m yyyy h:mm[am pm].
%form_submission_time_readabledate% This will show the date the user submitted the form in the format dd m yyyy.
%form_submission_time_readabletime% This will show the time the user submitted the form in the format hh:mm[am pm].
%form_submission_time_iso8601% This will show the date and time the user submitted the form in ISO8601 format.
%form_submission_time_rfc2822% This will show the date and time the user submitted the form in RFC2822 format.
%form_submission_time_rfc2822-dateonly% This will show the date the user submitted the form in RFC2822 format.
%form_submission_time_ical% This will show the date and time the user submitted the form in iCalendar format.
%response_<parent_id>_<question_id>% This will show the response the user submitted for the question. <parent_id> is the asset ID of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section. <question_id> is the asset ID of the question.
%response_<parent_id>_<question_id>_raw% This will show the raw value for the response the user submitted for the question. <parent_id> is the assetid of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section.<question_id> is the asset ID of the question.
%response_<parent_id>_<question_id>_file_content% The content of a submitted file in the form submission, where <parent_id> is the ID of the Section of the form and <question_id> is the ID of the File Upload question.
%response_<parent_id>_<question_id>_file_size% The file size of a submitted file in the form submission, where <parent_id> is the ID of the Section of the form and <question_id> is the ID of the File Upload question
%response_<parent_id>_<question_id>_file_id% The asset ID of a submitted file in the form submission, where <parent_id> is the ID of the Section of the form and <question_id> is the ID of the File Upload question
%youtube_video_id% The ID of a YouTube video uploaded using the Upload YouTube Video submission action. This ID is used within the YouTube link of the uploaded file (i.e. http://www.youtube.com/watch?v=xxxx).
%youtube_video_published_date% The publish date of a YouTube video uploaded using the Upload YouTube Video submission action.
%youtube_video_link% The full link of a YouTube video uploaded using the Upload YouTube Video submission action.

For Password fields, the %response_<parent_id>_<question_id>% keyword will print a blank string to enforce security. If you need to print the value of a password field for use in things like Form Submission Actions, you can use the %globals_post_x% keyword.

Page List Entry Format

The keyword replacements listed below allow you to customise how each page is displayed in the Page List.

Keyword Replacement Information shown
%page_name% This will display the page list by the Asset name of the corresponding Section, Unattached Question or Confirmation Page.
%page_number% This will display the page list numerically.
%total_pages% This will display the page list as the total number of pages in the form. 

Keyword Replacements for the Custom Form on an Asset Listing

The keyword replacements listed below can be used on an Asset Listing page when listing form submissions.

Keyword Replacement Information shown
%question_name_X_qY% This will show the Title of the question. X is the assetid of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section; qY is the ID of the question, for example, %question_name_89_q1% (for question 89:q1).
%question_answer_X_qY% This will show the response to the question for the submission. X is the assetid of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section; qY is the ID of the question, for example, %question_answer_89_q1% (for question 89:q1).
%question_answer_key_X_qY% This will show the raw value for the response the user submitted for the question. X is the assetid of the Section the question has been added to or the asset ID of the Form Contents asset if the question does not belong to a section; qY is the ID of the question, for example, %question_answer_key_89_q1% (for questions 89:q1).
%question_answer_file_size_X_qY% The file size of a submitted file in the form submission, where X is the ID of the Section of the form and Y is the ID of the File Upload question
%question_answer_X_qY_file_id% The asset ID of a submitted file in the form submission, where X is the ID of the Section of the form and Y is the ID of the File Upload question