iphlex systems list of replacement code parameters
iphlexwebphlexdocumentation > replacement code parameters
show contents
hide contents

 

 

Many replacement codes can be modified by parameters. Parameters must be placed at the end of the normal replacement code, i.e. following the record identifier where there is one, separated by vertical stroke characters "|" (ascii 124), e.g.

#TITLE|UCASE#

#TEXT:*lanz_002|LCASE|NOHTML#

In parameters which include a value (e.g. LIMIT), this must be separated from the parameter by an equals sign ("="), e.g.

#wPAGE_TITLE1:*lanz1|LIMIT=20#

The order in which parameters are placed doesn't matter - they are always processed in the following order:

  • SHORT, LANG & ABS (these determine which data is retrieved),
  • BWZ
  • NOHTML
  • NOPICS
  • HTML
  • LIMIT (inluding DOTS)
  • LINES (inluding DOTS)
  • LCASE
  • UCASE
  • LINK (inluding LANG, ABS & TARGET)
Parameters are not case-sensitive.

see also:

top of page
parameter: SHORT

Causes retrieval of the short text from a text block instead of the main text.

This parameter can only be used with replacement codes which take their data either directly from a text block, or from a field which can be replaced by one. When the field in question is not replaced by a text block, this parameter has no effect.

e.g. #TEXT:*ip_links_103# This is an entirely random collection of links, some with logos, titles and descriptions, some with logos only, and some with only titles and descriptions. Its only purpose is to demonstrate some of the possibilities of webphlex.
  #TEXT:*ip_links_103|SHORT# links page: general description

see also:

top of page
parameter: LANG

Causes retrieval of a text or URL for the language specified instead of for the language currently being generated or displayed.

This parameter can only be used for texts and URLs which are language dependant.

e.g. #TEXT:*pageLastUpd# Page last updated:
  #TEXT:*pageLastUpd|LANG=nl# Pagina laatst gewijzigd:

e.g. #wPAGE_URL:*lanz1# index.html
  #wPAGE_URL:*lanz1|LANG=nl# index_nl.html

see also:

top of page
parameter: ABS

Retrieves an absolute address instead of trying to determine a relative one. This is sometimes necessary when an URL is to be used as input to a Javascript routine or a server-side application (CGI).

Note that this is always a remote location.

e.g. #wPAGE_URL:_index# index.html
  #wPAGE_URL:_index|ABS# http://www.iphlex.com/webphlex_doc/index.html

If the address refers to a web page group which has not been assigned to a server (or if the server's address is empty), an absolute address cannot be produced and this parameter will be ignored.

see also:

top of page
parameter: UCASE

Converts a text to upper case.

e.g. #TEXT:*pageLastUpd# Page last updated:
  #TEXT:*pageLastUpd|UCASE# PAGE LAST UPDATED:

top of page
parameter: LCASE

Converts a text to lower case.

e.g. #TEXT:*pageLastUpd# Page last updated:
  #TEXT:*pageLastUpd|LCASE# page last updated:

top of page
parameter: LIMIT

Limits the length of a text to a given number of characters.

WARNING: Be careful when using this parameter on a text which itself includes a replacement code. It is quite possible to truncate a text in the middle of a replacement code, giving unexpected results!

Parameter DOTS can be used to replace the last few characters of a truncated text with dots, to show there's more.

e.g. #TEXT:*pageLastUpd# Page last updated:
  #TEXT:*pageLastUpd|LIMIT=15# Page last updat

see also:

top of page
parameter: LINES

Limits the length of a text to a given number of lines.

Parameter DOTS can be used to append a series of dots to a truncated text, to show there's more.

see also:

top of page
parameter: DOTS

Replaces a given number of characters by dots at the end of a text which has been truncated by parameter LIMIT or LINES.

Note that with parameter LIMIT the dots replace the last part of the text, whereas with parameter LINES they are appended to it. The maximum number of dots is 50.

This parameter can only be used together with parameter LIMIT or LINES.

e.g. #TEXT:*pageLastUpd# Page last updated:
  #TEXT:*pageLastUpd|DOTS=3|LIMIT=15# Page last up...

see also:

top of page
parameter: HTML

Adds simple HTML codes to a text by replacing line breaks with <P> and <BR>.

e.g. line1

line2
line3

line1<P>line2<BR>line3  

top of page
parameter: NOHTML

Removes all HTML codes from a text.

e.g. <B><FONT SIZE=3>line1</FONT></B>
<P>line2
<BR>line3
line1

line2
line3

 

top of page
parameter: NOPICS

Removes all HTML images from a text.

e.g. #TEXT:text1|NOPICS# :

  line1
<BR>line2 <IMG SRC="image.jpg">
<BR>line3
line1
<BR>line2
<BR>line3
 

If a string is supplied as a value, the HTML images will be replaced by this string.

e.g. #TEXT:text1|NOPICS=[image]# :

e.g. line1
<BR>line2 <IMG SRC="image.jpg">
<BR>line3
line1
<BR>line2 [image]
<BR>line3
 

top of page
parameter: BWZ

Replaces a number by a space character when it is zero (blank when zero).

e.g. #FILE_SIZE_BYTES# 0
  #FILE_SIZE_BYTES|BWZ#

top of page
parameter: LINK

Converts the retrieved text into a hypertext link.

e.g. #PAGE_GROUP_URL# ref_repl_params.html
  #PAGE_GROUP_URL|LINK# ref_repl_params.html

e.g. #wPAGE_TITLE1:*belgium# Belgium info
  #wPAGE_TITLE1:*belgium|LINK# Belgium info

For replacement codes which retrieve an address (e.g. #PAGE_GROUP_URL# and #ELEMENT_URL#), the hypertext link will point to the address retrieved, as in the first example. For all other codes, the link will point to the address of the web page group or element from which the data was retrieved. For example, the result of code #TITLE# will be linked to a web page group, and that of #ELEMENT_TITLE# to an element (i.e. to the position of the element on its main page, as retrieved by code #ELEMENT_URL#).

The main point of this parameter is to avoid having to specify record identifiers twice, with the danger of changing one and forgetting to change the other. E.g. the statement
<A HREF="#wPAGE_URL:*belgium#">#wPAGE_TITLE1:*belgium#</A>
can be replaced by
#wPAGE_TITLE1:*belgium|LINK#

Parameters LANG and ABS can be used in combination with LINK to influence the address used in the hyperlink. Note that Parameter LANG can be used even when the replacement code is not itself language-dependent.

For replacement codes which retrieve an address, the address in the hyperlink is always identical to that retrieved, and will be influenced by parameters such as LCASE etc. For all other codes, any parameters other than LANG which are used to influence the result (e.g. LCASE, LIMIT etc.) will have no effect on the hyperlink address.

Parameter TARGET can be used to add a target to the hyperlink.

see also:

top of page
parameter: TARGET

Adds a target to the hyperlink produced by parameter LINK.

If a value is specified, e.g. TARGET=_blank, that value will be used.

If the parameter is used without a value, i.e. simply TARGET, the target specified for the main page, detail page or element will be used, if there is one.

This parameter can only be used together with parameter LINK.

see also:

top of page
iphlexwebphlexdocumentation > replacement code parameters Copyright © 2006 iphlex systems