path- the path to the Vae text structure you wish to output. Uses VaeQL syntax.
param- name of a request parameter. If set, will output the value stored in that request parameter. The value will be HTML sanitized.
placeholder- renders a placeholder value that will be filled in with the real value from an eCommerce order once it is available to the system. This attribute is useful for building E-Mail templates that are associated with eCommerce orders.
Valid values for the placeholder attribute are:
id, which will insert the order ID number,
noteswhich will be replaced with order notes,
passwordwhich will be replaced with the new password assigned to a user in a forgot password email,
shipment_company, which will insert the shipping company,
shipment_date, which will insert the date of shipment, and
shipment_tracking_number, which will insert the shipping tracking number,
text- text that will be rendered directly.
after- text that will be added after the rendered text.
asset_height- if this is a rich text field with embedded assets such as video or images, setting this attribute will scale these assets to be no bigger than this many pixels high. If you provide
asset_height, you must also provide
$asset_quality[(optional)] - set to an integer from 1 to 100 to define the JPG quality of embedded image assets. If an embedded image asset is not a JPEG, this value is ignored.
asset_width- similar to
asset_height, but for width. If you provide
asset_width, you must also provide
audio_player_vars- string of ampersand-delimited options to customize the audio player that may be displayed if a Rich Text structure contains audio files. The available options are listed on the audio player website.
before- text that will be prepended to the rendered text.
color- text color to be used when an image is generated from the text.
font- if specified, the font will be rendered into an image using the font you specified. The
.ttffile for this font must be in the root directory of your website.
font-size- font size to be used when an image is generated from the text.
kerning- kerning (inter-character spacing) in pixels to be used when an image is generated from the text.
links_to_new_window- if set to
external, all external links will be rendered to open in a new window when clicked. If set to anything else, all links (internal and external) will be rendered to open in a new window when clicked.
max-width- maximum width (in pixels) of the image to be generated when an image is generated from the text.
maxlength- maximum length of the string to be displayed (in number of characters). If the text is longer than this, it will be clipped and an elipses (
…) will be inserted.
nohtml- if set to
true, all HTML tags will be from the output, replacing
<br />tags with newlines.
number_format- if present, the text string will be formatted with grouped thousands. The value of this attribute will control the number of displayed decimal places. For example
number_format="2"would cause the string
10000to render as
10,000.00. If the
afterattributes are also present, then those values are prepended or appended to the number prior to formatting.
padding- padding (in pixels) to be used when an image is generated from the text.
section- If the structure specified in the path attribute is a Rich Text Area, specify a number here to only render a certain section of the content. Content in a Rich Text Area may be divided by creating dividers in the editor widget in the backstage. The content before the first divider is considered section
0, after the first divider but before the second divider is section
section="0"will render just the first section. You may also add a plus sign (
+) to render a section and all sections after it. So
section="1+"would show the first section and all other sections as well.
strftime- if the structure specified by path is a Date or Time Structure, you may specify a strftime format string in this attribute and it will be used to format the date. In addition to the standard format parameters, Vae also supports a custom
%Nformat string that provides a “natural” description of the time, such as ‘3 hours ago’.
transform- if set to
uppercase, text will be turned into uppercase.
This tag is usually self-closed.
There are a number of possible uses for the
<v:text> tag. We will try
to cover several of them with sample code.
Would render something like this:
This article was written on: September 26, 2008.
Rendering text in a specific font
Rendering a Rich Text Area
HELLO WO ...