A Idoc Script Functions and Variables
Idoc Script has many built-in global functions. Functions perform actions, including string comparison and manipulation routines, date formatting, and ResultSet manipulation. Some functions also return results, such as the results of calculations or comparisons.
Information is passed to functions by enclosing the information in parentheses after the name of the function. Pieces of information that are passed to a function are called parameters. Some functions do not take parameters; some functions take one parameter; some take several. There are also functions for which the number of parameters depends on how the function is being used.
In addition to the built-in global functions, you can define new global functions, including custom classes, with Java code. For more information, see Getting Started with Content Server Components, and Creating Custom Components.
Along with built-in functions, Idoc Script uses a range of variables. Variables which are used within Idoc scripts include dynamic variables, conditional dynamic variables, and page display variables. Many of these variables can be used both within scripts and specified individually in the WebCenter Content config.cfg
and intradoc.cfg
files, or used in a web browser URL.
For details about variables that are used only in .cfg
files or in a web browser URL, see Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content.
A.1 abortToErrorPage()
Aborts the current page and displays an error message.
- This function evaluates the StatusCode variable, and if a negative numeric value (
-1
) is returned, substitutes the display of the current page with an error page. - The StatusMessage variable can be used as the error message string.
Type and Usage
Parameters
The only parameter is the error message string.
Output
Returns the error message string on an error page.
Example
Aborts the current page and displays Access Denied
as an error message:
<$abortToErrorPage("Access Denied")$>
Aborts the current page and displays the value of the StatusMessage variable as an error message:
<$abortToErrorPage("<$StatusMessage$>")$>
A.2 addEmptyOption
Specifies that a metadata field option list has blank value as the first option in the list.
Type and Usage
Output
- Returns
TRUE
if the first value in the option is blank. - Returns
FALSE
if the first value in the option list is not blank.
Example
Specifies that the first value in the option list is blank:
<$if ForceDocTypeChoice and isTrue(ForceDocTypeChoice)$> <$addEmptyOption = 1$> <$endif$>
See Also
A.3 AdminAtLeastOneGroup
Checks if the current user has the admin
role for at least one security group.
Type and Usage
Output
- Returns
TRUE
if the user is an administrator for at least one security group. - Returns
FALSE
if the user is not assigned theadmin
role.
Example
Can be used to do an optional presentation for an administrator:
<$if (AdminAtLeastOneGroup)$> <a href="<$redirect$>"> <$endif$>
See Also
A.4 AdsSimpleAuth
Specifies whether Oracle WebCenter Content Server roles and accounts are derived from Active Directory groups.
- When set to
TRUE
, only user passwords are authenticated from Active Directory; roles and accounts must be derived from another user base (such as an LDAP server). - When set to
FALSE
, roles and accounts are derived from Active Directory groups. - Default is
FALSE
.
Type and Usage
- Configuration Variables, described inOracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
- External Security
Location
instance_dir
/data/users/config/filter.hda
Example
Used as a configuration entry:
AdsSimpleAuth=true
A.5 AdsUserName
Specifies a user name that has Read permission for Active Directory.
- This setting is required only if the web server is running on a Windows Server that does not have Read permission to Active Directory.
- The user name must be in the form
DOMAIN_NAME
\
user_name
. - If this setting and the
AdsUserPassword
setting are not specified, the default is the user name that the web server runs under.
Usage
Location
- Active Directory Configuration page-User Name
instance_dir
/data/users/config/filter.hda
Example
Used as a configuration entry:
AdsUserName=CORP_DOMAIN\admin_user
See Also
A.6 AdsUserPassword
Specifies the password for the AdsUserName setting, which specifies a user name that has Read permission for Active Directory.
- This setting is required only if the web server is running on a Windows Server that does not have Read permission to Active Directory.
- If the AdsUserName setting and this setting are not specified, the default is the user name that the web server runs under.
Type and Usage
- Configuration Variables described in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
- External Security
Location
- Active Directory Configuration page-User Password
instance_dir
/data/users/config/filter.hda
Example
Used as a configuration entry:
AdsUserPassword=idc
See Also
A.7 AfterLogin
Specifies whether the current page was created immediately after a login.
Type and Usage
Output
- Returns
TRUE
if the page was created immediately after a login. - Returns
FALSE
if the page was not created immediately after a login.
Example
Displays an alternate URL if the page was not created immediately after a login:
<$if not AfterLogin$> <a href="<$redirect$>"> <$endif$>
A.8 AllowCheckin
Checks if the current user has checkin permission for the content item's security group.
Type and Usage
Output
- Returns
TRUE
if the user has checkin permission. - Returns
FALSE
if the user does not have checkin permission.
Example
Can be used to do an optional presentation for a user with checkin permission:
<$if (AllowCheckin)$> <a href="<$redirect$>"> <$endif$>
A.9 AllowCheckout
Checks whether current user has checkout permission for the content item's security group.
Type and Usage
Output
- Returns
TRUE
if the user has checkout permission. - Returns
FALSE
if the user does not have checkout permission.
Example
Can be used to do an optional presentation for a user with checkout permission:
<$if (AllowCheckout)$> <a href="<$redirect$>"> <$endif$>
A.10 AllowIntranetUsers
Checks if Microsoft network (NTLM) authentication is enabled.
Type and Usage
Output
- Returns TRUE if NtlmSecurityEnabled is set to TRUE.
- Returns FALSE if NtlmSecurityEnabled is set to TRUE.
Example
Evaluates Microsoft network security:
<$AllowIntranetUsers$>
See Also
- NtlmSecurityEnabled in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content.
A.11 AllowReview
Checks if the current user is allowed to approve or reject the current workflow item.
Type and Usage
Output
- Returns
TRUE
if the user is a reviewer for the current workflow step. - Returns
FALSE
if the user is not a reviewer for the current workflow step.
Example
Displays Approve and Reject buttons if the user is a reviewer:
<$if AllowReview$> <$include workflow_doc_action_buttons$> <$endif$>
A.12 AuthorAddress
Specifies the email address of the author of a content item.
Type and Usage
Output
Returns a string or Boolean value depending on use.
- Standard use: Returns the email address of the content item's author as a string.
- Used in a conditional statement:
- Returns
TRUE
if the content item author has a defined email address. - Returns
FALSE
if the content item author has no email address.
- Returns
Example
Can be used to alert the content item author through email when a revision is made.
<$AuthorAddress$>
A.13 AuthorDelete
Enables authors to delete their own revisions without Delete permission to the security group.
- When set to
TRUE
, authors can delete their own revisions without Delete permission to the security group. - Default is an empty string.
Type and Usage
- Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
- Internal Security
Location
- System Properties, Content Security tab, Allow author to delete revision
- Administration, Admin Server, Content Security menu option, Allow author to delete revision
IntradocDir
/config/config.cfg
Example
As a configuration entry:
AuthorDelete=true
As Idoc Script:
<$if AuthorDelete$> <$AuthorDelete$> <$else$> false <$endif$>
A.14 AutoNumberPrefix
Defines the prefix that will be added to all automatically numbered content IDs.
- Returns the automatic numbering prefix (returns value in configuration settings).
- Returns a string.
Type and Usage
- Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
- Content Items
Location
- System Properties, Options tab, Auto Name Prefix
- Administration, Admin Server, General Configuration menu option, Auto Number Prefix
IntradocDir
/config/config.cfg
Example
As a configuration setting, defines the automatic numbering prefix:
AutoNumberPrefix=HR
As Idoc Script, returns the value of the configuration setting:
<$AutoNumberPrefix$>
See Also
- "IsAutoNumber" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.15 BatchLoaderPath
Defines the path to the default batch load text file.
Returns the file path as a string.
Type and Usage
- Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
- Batch Loader
Location
DomainHome
/ucm/cs/bin/intradoc.cfg
Example
- As a Windows configuration entry:
BatchLoaderPath=c:/domain/BatchLoader/batchfile.txt
- As a Solaris/UNIX configuration entry:
BatchLoaderPath=/u1/intradoc3/batLd/batchfile
- As Idoc Script, returns the file path as a string:
<$BatchLoaderPath$>
A.16 break()
Often used to terminate a loop.
- The break instruction causes the innermost loop to be exited.
- Control resumes with the first statement following the end of the loop.
Type and Usage
A.17 BrowserVersionNumber
Retrieves the version number of the client browser.
Type and Usage
Output
Returns the browser version number as a string.
Example
Can be used to ensure that the user has a browser version compatible with Oracle WebCenter Content Server.
<$BrowserVersionNumber$>
A.18 c
Specifies a comment in Idoc Script code.
Type and Usage
Example
Places a comment in the code:
<$c = "Sets the variables to empty strings."$>
A.19 cacheInclude()
This function acts similar to the inc()
Idoc Script function. It will evaluate the dynamic HTML include corresponding to includeName
and display it on the page. The difference is that if possible, it will pull the rendered html from a cache, instead of evaluating it again.
For more information, see Keywords Versus Functions.
Type and Usage
Parameters
Takes three required parameters and two optional parameters. For example:
cacheInclude(includeName, scope, lifeSpan[, cacheName][, key])
Parameter | Description |
---|---|
includeName |
The name of the dynamic HTML element to evaluate. |
scope |
Set to session if each user should see different html, or application if all users will see the same thing.
|
lifeSpan |
The lifespan of this include in the cache, in seconds. |
cacheName |
Optional: Use if you want to place the data into a named cache instead of the default cache. If an empty string is passed, the include will be cached into the default cache for the session. |
key |
Optional: If you do not want automatic name-scoping of your cache to prevent conflicts, you can specify a unique key here. |
Example
This will cache the std_page_begin
include for each user for ten minutes. This is about 10 KB per user in the cache.
<$cacheInclude("std_page_begin", "session", 600)$>
A.20 captionEntryWidth
Specifies the width of a metadata field, as a percentage.
Type and Usage
Output
Returns the width of the current metadata field, as a percentage.
Example
Used as script:
<$if isInfo$> <$captionFieldWidth="30%"$> <$captionEntryWidth="70%"$> <$elseif isEditMode$> <$captionFieldWidth="20%"$> <$captionEntryWidth="80%"$> <$endif$>
See Also
A.21 captionFieldWidth
Specifies the width of a metadata field caption, as a percentage.
Type and Usage
Output
Returns the width of the current metadata field caption, as a percentage.
Example
Used as script:
<$if isInfo$> <$captionFieldWidth="30%"$> <$captionEntryWidth="70%"$> <$elseif isEditMode$> <$captionFieldWidth="20%"$> <$captionEntryWidth="80%"$> <$endif$>
See Also
A.22 clearSchemaData()
Clears the data from a schema ResultSet.
Type and Usage
Parameters
This function can take zero, one, or two parameters.
- If passed zero arguments, it clears the data binder. Returns no value.
- If passed one argument, the argument is the name of the ResultSet to clear the values from the current row. Returns no value.
- If passed two arguments, the first argument is the ResultSet name and the second argument is the key identifying the data object to clear. Returns
0
if the data does not exist or1
if it does exist. The use isTrue()
orFalse()
to conditionally execute scripts based on the return value.
Example
<$clearSchemaData()$>
See Also
A.23 ClientControlled
Checks if the page was accessed from the ODMA Client.
This value is passed by the string for controlling the update process that is provided by the client.
Type and Usage
Output
- Returns
TRUE
if the page was accessed from the ODMA Client. - Returns
FALSE
if the page was not accessed from the ODMA Client.
Example
Checks if the page was accessed from the ODMA Client:
<$ClientControlled$>
See Also
A.24 computeDocUrl()
This function computes the URL to a content item based on the data on the page. computeDocUrl() accepts two boolean (0 or 1) arguments. The first argument is that the URL is relative or absolute and the second argument is should be that the exception be thrown or ignored.
For example, this function can be called to generate a URL to an item when looping over a ResultSet of items.
The following information must be present on the page:
dDocAccount
(optional)dDocName
dDocType
dProcessingState
dRevLabel
dSecurityGroup
dWebExtension
Type and Usage
Parameters
computeDocUrl() accepts two boolean (0 or 1) arguments. There is now a second parameter. The values are the same as the first parameter set toTRUE (1)
or FALSE (0)
. Default value is false
.
A.25 computeRenditionUrl()
Returns the URL of a given rendition.
Type and Usage
Parameters
Takes three parameters:
- The first parameter is the URL of the content item.
- The second parameter is the
dRevLabel
value. - The third parameter is the
dRendition1
value. Possible values ofdRendition1
include:T
= Thumbnail renditionX
= XML rendition
Output
Returns the complete URL of the rendition as a string.
Example
Returns the URL of the rendition as a string.
<$computeRenditionUrl(url, dRevLabel, dRendition1)$>
A.26 CONTENT_LENGTH
Retrieves the length in bytes of the requested content item as supplied by the client.
This variable is specific to the current gateway program request.
Note:
This setting is obsolete for Content Server version 7.0 and later. The web server filter no longer sends this information.
Type and Usage
Output
Returns the content length in bytes.
Example
As information output on a page or to a log:
CONTENT_LENGTH=0
As part of an Idoc Script statement or evaluation:
<$if CONTENT_LENGTH$>
<!--statement-->
A.27 coreContentOnly
Set this variable in the URL of a service request to display only the form. The std_page_begin
and std_page_end
include files will not be displayed.
Type and Usage
Output
None.
A.28 CURRENT_DATE
Returns the current date and time.
This variable is similar to the dateCurrent() function, which is used more frequently.
Type and Usage
Output
Returns a string formatted according to the user locale.
Example
Used as script:
<$CURRENT_DATE$>
See Also
A.29 CURRENT_ROW
Evaluates which row of a ResultSet you are in.
The first row in a ResultSet is row zero (0).
Type and Usage
Output
Returns the row number.
Example
Used as script:
<$CURRENT_ROW$>
A.30 dateCurrent()
Returns the current date and time.
Can be used to return the current date and time to the user or to create commands using date evaluations.
Type and Usage
Parameters
The only optional parameter is an integer, which adjusts the date by the specified number of days relative to the current date.
Output
Returns a date formatted according to the user locale.
Example
In the following examples, dates are formatted according to the default English-US
locale:
m/d/yy h:mm XM
The following returns the current date and the current time (for example, 8/12/01 1:55 PM
):
<$dateCurrent()$>
Returns the date ten days in the future and the current time (for example, 8/22/01 1:55 PM
):
<$dateCurrent(10)$>
Returns the date ten days in the past and the current time (for example, 8/2/01 1:55 PM
):
<$dateCurrent(-10)$>
See Also
A.31 dcShowExportLink
This function verifies if the Dynamic Converter has been configured to convert a content item. The returned value is based on the value for dFormat
for the item.
This function is typically used on Search Result pages to conditionally display a Dynamic Converter link.
Type and Usage
Output
-
Returns
TRUE
if the Dynamic Converter is configured to convert the content item. -
Returns
FALSE
if the Dynamic Converter is not configured.
Example
<$QueryText = "dDocTitle <substring> `test`"$> <$executeService("GET_SEARCH_RESULTS")$> <$loop SearchResults$> <$if dcShowExportLink()$> <a href="<$HttpCgiPath$>?IdcService= GET_DYNAMIC_CONVERSION&dID=<$dID$>"> HTML Conversion of <$dDocTitle$></a> <$endif$> <$endloop$>
A.32 ddAppendIndexedColumnResultSet()
This function loads a dynamicdata table into a ResultSet. It is very similar to ddLoadIndexedColumnResultSet
. The main difference is that if the Idoc Script ResultSet already exists, the new ResultSet created from the dynamicdata table is appended to it. Any fields found in the dynamicdata table, but not in the target ResultSet, are automatically added.
Type and Usage
Parameters
The following table lists parameters for this function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to load. |
|
The name of the ResultSet into which the dynamicdata table should be appended. |
|
The name of an indexed column in the dynamicdata table. |
|
The value to use to select a section of the original table. This value will be checked in a case-insensitive manner against the |
|
The name of a dynamicdata table used to rename the columns of the final ResultSet. The renaming is done by mapping the column names in the specified mapping table to the values of the first row in the same table. This is done exactly the same in |
Output
If the dynamicdata table is successfully loaded, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> <?commatable indexedColumns="fieldA"?> fieldA, fieldB, fieldC 1, 2, 3 4, 5, 6 1, 3, 9 <@end@> <$exec rsCreateResultSet("MyResultSet", "fieldA,fieldB")$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.fieldA = "first value"$> <$MyResultSet.fieldB = "second value"$> <$exec ddLoadIndexedColumnResultSet("MyDataTable", "MyResultSet", "fieldA", "1")$> <$exec rsFirst("MyResultSet")$> <$foo = MyResultSet.fieldB$> [[% (foo == 'second value') %]]<$exec rsNext("MyResultSet")$> <$bar = MyResultSet.fieldC$> [[% (bar == '3') %]]
See Also
A.33 ddAppendResultSet()
This function loads a dynamicdata table into a ResultSet. It is very similar to ddLoadResultSet
. The main difference is that if the Idoc Script ResultSet already exists, the new ResultSet created from the dynamicdata table is appended to it. Any fields found in the dynamicdata table, but not in the target ResultSet, are automatically added.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to load. |
|
The name of the ResultSet into which the dynamicdata table should be appended. |
|
The name of a dynamicdata table used to rename the columns of the final ResultSet. The renaming is done by mapping the column names in the specified mapping table to the values of the first row in the same table. This is done exactly the same in |
Output
If the dynamicdata table is successfully loaded, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> field1, field2, field3 a, b, c d, e, f <@end@> <$exec rsCreateResultSet("MyResultSet", "field1,field2")$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.field1 = "first value"$> <$MyResultSet.field2 = "second value"$> <$exec ddAppendResultSet("MyDataTable", "MyResultSet")$> <$exec rsFirst("MyResultSet")$> <$foo = MyResultSet.field1$> [[% (foo == 'first value') %]] <$exec rsNext("MyResultSet")$> <$bar = MyResultSet.field3$> [[% (bar == 'c') %]]
A.34 ddApplyTableSortToResultSet()
This function sorts an existing ResultSet using the rules defined in a particular dynamicdata table.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to use for its sorting rules. |
|
The name of the ResultSet into which the dynamicdata table should be appended. |
Output
If the sorting is successfully performed, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> <?commatable sortcolumn="order" sortType="int" sortOrder="asc"?> user, service, order jane, DOC_INFO, 10 bob, GET_SEARCH_RESULTS, 20 annette, CHECKIN_NEW, 30 <@end@> <$exec rsCreate("MyResultSet")$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.user = "james"$> <$MyResultSet.service = "GET_FILE"$> <$MyResultSet.order = 75$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.user = "zoe"$> <$MyResultSet.service = "DOC_INFO_BY_NAME"$> <$MyResultSet.order = 20$> <$exec ddApplyTableSortToResultSet("MyDataTable", "MyResultSet")$>
A.35 ddGetFieldList()
This function takes a dynamicdata table and returns a comma-separated string containing the names of the columns in the table. It is expected that many dynamicdata tables consist only of field names without any rows just to supply comma-separated lists of values to code in the Content Server system.
Type and Usage
Parameters
This function has one parameter, dataTableName
, which is the name of the dynamicdata table to load.
Output
If the dynamictable exists, it returns True.
Example
<@dynamicdata MyDataTable@> foo,bar,baz <@end@> <$fieldList = ddGetFieldList("MyDataTable")$> <$trace(fieldList, "#console")$> [[% Outputs: foo,bar,baz %]]
A.36 ddIncludePreserveValues()
This function executes a resource include, but protects values specified by a dynamicdata table from being changed. The column names in the data table are used as the list of variables names that must be protected. These variables are protected by temporarily caching them, calling the include, and then resetting those variables back to the cached values. If a variable was null, it is set to blank.
If one of the column names in the table starts with a dollar symbol ($
), then the string that follows is assumed to be the name of a ResultSet. In that case, it is the pointer to the ResultSet that is temporarily cached in memory and then replaced after the resource include has finished executing. If the ResultSet did not exist at the time of caching, then any ResultSet that exists with that key at the end are removed. If the ResultSet is active at the time it has its pointer cached, new ResultSets of the same name can be created during the call of the include and the previously active ResultSet will be recovered appropriately without disturbing the loop. The one side effect is that if a new ResultSet is created that temporarily replaces the active ResultSet, then the algorithm for variable substitution that retrieves values first from active ResultSets can find values for a variable from the cached active ResultSet (assuming the variable is not found as a field in an active ResultSet with higher precedence). The cached active ResultSet maintains its place in the active ResultSet stack,
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the resource include to execute. |
|
The name of the dynamicdata table to use for preserving local data and ResultSets. |
Output
A string representing the output of the executed resource include.
Example
<@dynamicdata MyPreservedFields@> foo, bar, $baz <@end@> <@dynamichtml my_include@> <$foo = "tempValue1"$> <$bar = "tempValue2"$> <@end@> <$foo = 5$> <$ddIncludePreserveValues("my_include", "MyPreservedFields")$> <$trace(foo, "#console")$> [[% Outputs: 5 %]]
A.37 ddLoadIndexedColumnResultSet()
This function loads a dynamicdata table into a ResultSet. This function is similar to ddLoadResultSet
except that it only loads those rows whose values for indexColumn
match indexValue
. The comparisons made on this column are case-insensitive.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to load. |
|
The name of the ResultSet into which the dynamicdata table should be loaded. |
|
The name of an indexed column in the dynamicdata table. |
|
The value to use to select a section of the original table. This value will be checked in a case-insensitive manner against the |
|
The name of a dynamicdata table used to rename the columns of the final ResultSet. The renaming is done by mapping the column names in the specified mapping table to the values of the first row in the same table. This is done exactly the same in |
Output
If the dynamicdata table is successfully loaded, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> <?commatable indexedColumns="fieldA"?> fieldA, fieldB, fieldC 1, 2, 3 4, 5, 6 1, 3, 9 <@end@> <$exec ddLoadIndexedColumnResultSet("MyDataTable", "MyResultSet", "fieldA", "1")$> <$exec rsFirst("MyResultSet")$> <$foo = MyResultSet.fieldB$> [[% (foo == '2') %]] <$exec rsNext("MyResultSet")$> <$bar = MyResultSet.fieldC$> [[% (bar == '9') %]]
See Also
A.38 ddLoadResultSet()
This function loads a dynamicdata table into a ResultSet.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to load. |
|
The name of the ResultSet into which the dynamicdata table should be loaded. |
|
The name of a dynamicdata table used to rename the columns of the final ResultSet. The renaming is done by mapping the column names in the specified mapping table to the values of the first row in the same table. This is done exactly the same in |
Output
If the dynamicdata table is successfully loaded, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> fieldA, fieldB, fieldC 1, 2, 3 4, 5, 6 1, 3, 9 <@end@> <$exec ddLoadResultSet("MyDataTable", "MyResultSet")$> <$exec ddLoadResultSet("MyDataTable", "MyAliasedResultSet")$> <$exec rsFirst("MyResultSet")$> <$exec rsFirst("MyAliasedResultSet")$> <$foo = MyResultSet.field1$> [[% (foo == 'a') %]] <$bar = MyAliasedResultSet.alias2$> [[% (bar == 'c') %]]
See Also
A.39 ddMergeIndexedColumnResultSet()
This function merges a dynamicdata table into a ResultSet. This function is similar to ddMergeResultSet
except that it only merges those rows whose values for indexColumn
match indexValue
. The comparisons made on this column are case-insensitive.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to load. |
|
The name of the ResultSet into which the dynamicdata table should be merged. |
|
The name of an indexed column in the dynamicdata table. |
|
The value to use to select a section of the original table. This value is checked in a case-insensitive manner against the indexColumn in each row. If it matches, that row is loaded into the ResultSet; otherwise it is skipped. |
|
The type of merge to perform. Set this to |
|
The name of a dynamicdata table which should be used to rename the columns of the final ResultSet. This renaming is done by mapping the column names in this mapping table to the values of the first row in this same table. This is done exactly as it is done in |
Output
If the dynamicdata table is successfully merged, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> fieldA, fieldB, fieldC 1, 2, 3 4, 5, 6 1, 3, 9 <@end@> <$exec rsCreateResultSet("MyResultSet", "fieldA,fieldB,fieldC")$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.fieldA = "4"$> <$MyResultSet.fieldB = "8"$> <$MyResultSet.fieldB = "23"$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.fieldA = "8"$> <$MyResultSet.fieldB = "21"$> <$MyResultSet.fieldB = "59"$> <$exec ddMergeIndexedColumnResultSet("MyDataTable", "MyResultSet", "fieldA", "4", "replace")$> <$exec rsFirst("MyResultSet")$> <$foo = MyResultSet.fieldB$> [[% (foo == '5') %]] <$exec rsNext("MyResultSet")$> <$bar = MyResultSet.fieldC$> [[% (bar == '59') %]]
See Also
A.40 ddMergeResultSet()
This function merges a dynamicdata table into an existing ResultSet. If the target ResultSet does not exist, then this function acts exactly like ddLoadResultSet
and the target ResultSet is simply created. Otherwise, the merge is performed using the first column of the new ResultSet as the merge key. By default, the merge appends any rows from the new ResultSet that do not match any rows in the existing Idoc Script table, unless the mergeType
parameter is set to replace, in which case no new rows are added to the Idoc Script ResultSet.
Note that this merge does not replace all rows matched by a particular row of the new ResultSet, just the first one that it finds. The matching is case-sensitive. The mergeType parameter is optional and defaults to null.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to load. |
|
The name of the ResultSet into which the dynamicdata table should be merged. |
|
The type of merge to perform. Set this to |
|
The name of a dynamicdata table which should be used to rename the columns of the final ResultSet. This renaming is done by mapping the column names in this mapping table to the values of the first row in this same table. This is done exactly as it is done in |
Output
If the dynamicdata table is successfully merged, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> fieldA, fieldB, fieldC 1, 2, 3 4, 5, 6 <@end@> <$exec rsCreateResultSet("MyResultSet", "fieldA,fieldB,fieldC")$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.fieldA = "4"$> <$MyResultSet.fieldB = "52"$> <$MyResultSet.fieldC = "18"$> <$exec ddMergeResultSet("MyDataTable", "MyResultSet", "replace")$> <$exec rsFirst("MyResultSet")$> <$foo = MyResultSet.fieldB$> [[% (foo == 52) %]] <$bar = MyResultSet.#numRows$> [[% (bar == 1) %]]
See Also
A.41 ddMergeUsingIndexedKey()
This function pulls selective rows from a dynamicdata table and use them to replace particular row values in a target ResultSet. The values of a particular column in the target ResultSet are used as values for an index look up into the dynamicdata table. The subtable retrieved is used to replace column values in the target ResultSet that have matching column names. The dynamicdata table is assumed to have only one row in the subtable selected out by the index value. If it has more than one row, only the first row is used to merge in values into the target ResultSet.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to load. |
|
The name of the ResultSet into which the dynamicdata table should be merged. |
|
The name of an indexed column in the dynamicdata table and the name of the column in the target ResultSet from which values are retrieved to select out subtables in the dynamicdata table. |
|
The name of a dynamicdata table which should be used to rename the columns of the final ResultSet. This renaming is done by mapping the column names in this mapping table to the values of the first row in this same table. This is done exactly as it is done in |
Output
If the dynamicdata table is successfully merged, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> <?commatable indexedColumns="fieldA"?> fieldA, fieldB, fieldC 1, 2, 3 4, 5, 6 7, 8, 9 <@end@> <$exec rsCreateResultSet("MyResultSet", "fieldA,fieldB,fieldC")$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.fieldA = "4"$> <$MyResultSet.fieldB = "8"$> <$MyResultSet.fieldB = "23"$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.fieldA = "7"$> <$MyResultSet.fieldB = "20"$> <$MyResultSet.fieldB = "41"$> <$exec rsAppendNewRow("MyResultSet")$> <$MyResultSet.fieldA = "8"$> <$MyResultSet.fieldB = "21"$> <$MyResultSet.fieldB = "59"$> <$exec ddMergeIndexedColumnResultSet("MyDataTable", "MyResultSet", "fieldA")$> <$exec rsFirst("MyResultSet")$> <$foo = MyResultSet.fieldB$> [[% (foo == '5') %]] <$exec rsNext("MyResultSet")$> <$bar = MyResultSet.fieldC$> [[% (bar == '9') %]] <$exec rsNext("MyResultSet")$> <$bar = MyResultSet.fieldC$> [[% (bar == '59') %]]
A.42 ddSetLocal()
This function takes a dynamicdata table and iterates over it, setting local data values for each row. The first column of the table is used as the list of keys, while the second column is used as the list of values.
Type and Usage
Parameters
This function has one parameter, dataTableName
, which is the name of the dynamicdata table to load.
Output
If the dynamicdata table exists, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> key, value foo, 15 bar, 23 baz, 77 <@end@> <$exec ddSetLocal("MyDataTable")$> <$tmp1 = #local.foo$> [[% (tmp1 == '15') %]] <$tmp2 = #local.bar$> [[% (tmp2 == '23') %]] <$tmp3 = #local.baz$> [[% (tmp3 == '77') %]]
A.43 ddSetLocalByColumnsFromFirstRow()
This function takes the first row of a dynamicdata table and, using the column names as keys, sets a local value for each column and its corresponding value. If there is no first row, then this function does nothing. This can be a useful method for quickly setting a lot of local values. The filterInclude
and includeColumns
properties of the dynamicdata table are ignored.
Type and Usage
Parameters
This function has one parameter, dataTableName
, which is the name of the dynamicdata table to load.
Output
If the dynamicdata table was successfully loaded, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> fieldA, fieldB, fieldC foo, bar, baz <@end@> <$exec ddSetLocalByColumnsFromFirstRow("MyDataTable")$> <$tmpStr1 = #local.fieldA$> [[% (tmpStr1 == 'foo') %]] <$tmpStr2 = #local.fieldC$> [[% (tmpStr2 == 'baz') %]]
A.44 ddSetLocalByColumnsFromFirstRowIndexed()
This function takes the first row of a dynamicdata table, and, using the column names as keys, sets a local value for each column and its corresponding value. If there is no first row, then this function does nothing. This function is almost identical to ddSetLocalByColumnsFromFirstRow(). The only difference is that this function uses the first row given an indexed column and value instead of the very first row of the dynamicdata table. If no indexed row is found, then this function does nothing.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the dynamicdata table to load. |
|
The name of an indexed column in the dynamicdata table. |
|
The value to use to select a row of the original table. This value will be checked in a case-insensitive manner against the indexColumn in each row. If it matches, that row will be used and the rest of the table will be ignored. |
Output
If the dynamicdata table is successfully loaded, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> <?commatable indexedColumns="fieldB"?> fieldA, fieldB, fieldC 1, 2, 3 4, 5, 6 7, 8, 9 3, 5, 2 <@end@> <$exec ddSetLocalByColumnsFromFirstRowIndexed("MyDataTable", "fieldB", 5)$> <$tmpStr1 = #local.fieldA$> [[% (tmpStr1 == '4') %]] <$tmpStr2 = #local.fieldC$> [[% (tmpStr2 == '6') %]]
A.45 ddSetLocalEmpty()
This function takes a dynamicdata table and iterates over it, clearing local data. The first column is used as the keys to clear.
Type and Usage
Parameters
This function has one parameter, dataTableName
, which is the name of the dynamicdata table to use.
Output
If the dynamicdata table exists, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> key foo bar baz <@end@> <$foo = 1$> <$bar = 2$> <$baz = 3$> <$exec ddSetLocalEmpty("MyDataTable")$> <$if foo or bar or baz$> [[% This will not be executed as foo, bar, and baz are all empty. %]] <$endif$>
See Also
A.46 ddSetLocalEmptyByColumns()
This function takes a dynamicdata table and uses the columns to clear values in local data.
Type and Usage
Parameters
This function has one parameter, dataTableName
, which is the name of the dynamicdata table to use.
Output
If the dynamicdata table exists, it returns TRUE
.
Example
<@dynamicdata MyDataTable@> foo, bar, baz <@end@> <$bar = "asdf"$> <$exec ddSetLocalEmptyByColumns("MyDataTable")$> <$if bar$> [[% This will not execute as bar will be empty. %]] <$endif$>
See Also
A.47 DefaultAccounts
Defines the default accounts for anonymous users.
-
This must be a comma-delimited list of accounts.
-
Permissions for each account must be specified in parentheses after the account name.
-
The
#none
entry grants privileges to content items that have no account assigned. The#all
entry grants privileges to all accounts. -
Default is
#none(RWDA)
. -
Returns the list of accounts as a string.
Type and Usage
Location
IntradocDir
/config/config.cfg
Example
As a configuration setting, defines default account information:
DefaultAccounts=BOS(R),SEA(RW),MSP/Gen(RWD)
As Idoc Script, returns the account information as a string:
<$DefaultAccounts$>
See Also
-
“DefaultNetworkAccounts" in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.48 defaultFieldInclude
Specifies the include to use to display the metadata field.
Type and Usage
Example
Sets the default field-display include for a hidden field on a query page to std_query_hidden_field
:
<$if isFieldHidden$> <$if isQuery and not (fieldType like "Date") and not (fieldType like "Int")$> <$defaultFieldInclude = "std_query_hidden_field"$> <$endif$>
See Also
A.49 defaultOptionListScript
Defines a piece of Idoc Script that displays a standard option list field.
Type and Usage
Output
None.
Example
Generates an option list using the optList
function:
<$if optionsAllowPreselect and fieldValue$> <$defaultOptionListScript = "<$optList " & optionListName & ":fieldValue$>"$> <$else$> <$defaultOptionListScript = "<$optList " & optionListName & ":noselected$>"$> <$endif$>
Loops on the current option list ResultSet to generate an option list:
<@dynamichtml compute_resultset_option_list_script@> <$if not optionListKey$> <$optionListKey = fieldName$> <$endif$> <$defaultOptionListScript = "<$loop " & optionListResultSet & "$>" & "<$inc('std_resultset_option_list_item')$>" & "<$endloop$>"$> <@end@>
See Also
A.50 DelimitedUserRoles
Retrieves a comma-delimited, colon-delimited list of roles the current user belongs to.
Type and Usage
Output
Returns the user role list as a string.
Example
Returns a list of roles formatted as follows:
:guest:,:PublicContributor:,:ClassifiedConsumer:
See Also
A.51 docLoadResourceIncludes()
Loads all the includes in a specified content item for use in the display of the current page.
-
The content item specified must have the file extension
.idoc
. -
This function sets StatusCode as a side effect. Use the abortToErrorPage function if the specified file must successfully load for the page to correctly display.
Type and Usage
Parameters
Takes a CGI-encoded parameter list that specifies a content item that is checked into Content Server. The parameter options are listed in the following table.
Optional Parameters | Description |
---|---|
|
If |
|
It is recommended that
|
|
If present,
|
|
|
Note:
When used in HCSP pages, the ampersand character (&
) in the CGI-encoded parameter list must be changed to &
.
Output
None.
Example
Loads the resource includes in the primary vault rendition of the latest revision of mydoc
.
<$docLoadResourceIncludes("dDocName=mydoc&RevisionSelectionMethod=Latest")$>
See Also
A.52 docRootFilename()
Retrieves the file name of a file without the extension or directory path.
-
This function is typically used to extract the content ID (
dDocName
) part of a static URL controlled by Content Server.
Type and Usage
Parameters
Takes one parameter:
-
The only parameter is a path and file name.
Output
Returns the file name as a string.
Example
Returns the value mydoc
:
docRootFilename("/groups/public/documents/adacct/mydoc.pdf")
A.53 DocTypeSelected
Evaluates whether the Type of the current content item matches the Type in the active ResultSet.
Type and Usage
Output
-
Returns
TRUE
if the content item Types match. -
Returns
FALSE
if the content item Types do not match.
Example
Returns value based on whether the content item type matches the type for the ResultSet.
<$DocTypeSelected$>
A.54 DocUrl
Retrieves the URL of the file in the weblayout/
directory. This variable is evaluated once per content item, not once per service call.
Type and Usage
Output
Returns the URL of the file as a string.
Example
Used to build URL links to content items.
<$if HasUrl$> <a href="<$DocUrl$>"><$dDocName$></a> <$else$> <$dDocName$> <$endif$>
A.55 docUrlAllowDisclosure()
Evaluates whether a URL can be disclosed to the current user.
Type and Usage
Parameters
The only parameter is an absolute path, such as the following:
http://mycomputer/domain/groups/.../documents/mydoc.pdf
A full relative path can be used, such as the following:
/oracle/domain/.../documents/mydoc.pdf
).
Output
Returns a Boolean value.
-
Returns
TRUE
if the URL can be disclosed. -
Returns
FALSE
if the URL is restricted.
Example
Determines if the user can view the URL of the mydoc.pdf
document.
<$docUrlAllowDisclosure("/domain/groups/documents/mydoc.pdf")$>
A.56 DownloadApplet
Enables the multiple file Download Applet.
-
When set to
TRUE
, the Download Applet is enabled so that multiple files can be downloaded from a search results page. -
When set to
FALSE
, the Download Applet is disabled. -
Default is
FALSE
.
Note:
The DownloadApplet/UploadApplet will continue working as applets.Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Options tab, Enable download applet
-
Administration, Admin Server, General Configuration menu option, Enable download applet
-
IntradocDir
/config/config.cfg
Example
As a configuration setting, enables the Download Applet:
DownloadApplet=true
As script, evaluates the condition of the Download Applet:
<$DownloadApplet$>
See Also
A.57 DownloadSuggestedName
Retrieves the default path and suggested name for a file being downloaded.
The suggested name is based on the original file name of the content item.
Type and Usage
Output
Returns the path and suggested name for the downloaded file as a string.
Example
Returns the path and suggested name for the downloaded file:
<$DownloadSuggestedName$>
A.58 dpGet()
Function used to return the value set by the dpSet
function.
Both dpGet
and dpSet
are used to control the logic of Content Profile rules that are to be displayed. Commonly, a user may create an activation condition that sets a value for a specified key. Even if the condition evaluates to false (that is, the rule fails to fire), the key is set. Another rule can now access the key and retrieve the value when evaluating its activation condition. By using these two functions, a user can create a dependency between rules. For example, a user may want a rule to be evaluated only when a preceding rule is evaluated.
Type and Usage
Parameters
Takes one parameter:
-
Key: The designation for the value to be returned.
Example
<$myValue = dpGet("myKey")$>
See Also
A.59 dpPromote()
Function used to 'promote' values from a rule evaluation context into the request context. After the evaluation of all rules, the key and value specified by this function are pushed into the local data.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is the designation for the value to be returned.
-
The second parameter is the value to be returned.
Example
This example causes the Title field to be hidden on checkin pages:
<$dpPromote("dDocTitle:isHidden", "1")$>
See Also
A.60 dpPromoteRs()
Similar to dpPromote
, this function allows a ResultSet that is generated in a profile rule to be promoted to the request context. The ResultSet is pushed into the DataBinder after the evaluation of all rules. The values are not evaluated during rule activation or manipulation but are available for page presentation.
Type and Usage
Parameters
This function can take two parameters:
-
The first parameter is the name of the ResultSet to push into the data.
-
Optional. The second parameter is an alternate name for the ResultSet.
See Also
A.61 dpSet()
Function used to set temporary values during the evaluation of activation conditions or rule values anywhere Idoc Script is evaluated.
The values are set into a working area and can be retrieved by the dpGet
function call. The key and value that is set does not persist, but is globally available for the profile being evaluated. All key/value pairs can be accessed by the rules of the profile.
Both dpGet
and dpSet
are used to control the logic of Content Profile rules that are to be displayed. Commonly, a user may create an activation condition that sets a value for a specified key. Even if the condition evaluates to false (that is, the rule fails to fire), the key is set. Another rule can now access the key and retrieve the value when evaluating its activation condition. By using these two functions, a user can create a dependency between rules. For example, a user may want a rule to be evaluated only when a preceding rule is evaluated.
Type and Usage
Parameters
This function takes two parameters:
-
Key: The designation for the value to be returned.
-
Value: Value associated with the key.
Example
<$dpSet("myKey", "1")$>
See Also
A.62 dWfName
Retrieves the name of the workflow.
Type and Usage
Output
Returns the name of the workflow as a string.
Example
The following code in the IdcHomeDir
/resources/core/templates/workflow_info.htm
template page is used to display the workflow name on the Workflow Step Information page:
<td align=right><span class=infoLabel><$lc("wwLabelWorkflow")$></span></td>
<td><span class=tableEntry><$dWfName$></span></td>
A.63 dWfStepName
Retrieves the name of the current step in the workflow.
Type and Usage
Output
Returns the name of the current step as a string.
Example
The following code in the IdcHomeDir
/resources/core/templates/workflow_info.htm
template page is used to display the current step name on the Workflow Step Information page:
<td align=right><span class=infoLabel><$lc("wwCurrentStep")$>
</span></td>
<td><span class=tableEntry>
<$loop WorkflowStep$>
<$dWfStepName$>
<$exec RequiredUsers = dWfStepWeight$>
<$if isTrue(dWfStepIsAll)$><$exec RequiredUsers = 0$><$endif$>
<$endloop$></span>
</td>
A.64 EmptyAccountCheckinAllowed
Checks if an account must be specified on the checkin page.
Used on the Standard Page Resources page to display an error message if an account is not specified.
Type and Usage
Output
-
Returns
TRUE
if an Account value is required. -
Returns
FALSE
if an Account value is not required.
Example
Evaluates whether an account number is required and displays an error message.
<$if not EmptyAccountCheckinAllowed$> <$isRequired = 1, requiredMsg = "Please specify an account."$> <$endif$>
A.65 EnableDocumentHighlight
Enables highlighting of full-text search terms in PDF, text, and HTML files.
-
When set to
TRUE
, search term highlighting is enabled. -
When set to
FALSE
, search term highlighting is disabled. -
Default is
FALSE
after installation of Content Server. -
Default is
TRUE
after installation of PDF Converter.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Options tab, Enable search keyword highlighting
-
Administration, Admin Server, General Configuration menu option, Enable search keyword highlighting
-
IntradocDir
/config/config.cfg
Example
As a configuration setting:
EnableDocumentHighlight=false
As script, returns the value of the configuration setting:
<$EnableDocumentHighlight$>
See Also
A.66 encodeHtml()
Idoc function used to filter data input for illegal or corruptive HTML constructs. This function is used by default in Threaded Discussions, a component available during installation.
All input data received by Content Server when using the unsafe
value for the rule
parameter applies only to well-known unsafe script tags. This functionality can be altered by using the HtmlDataInputFilterLevel
configuration variable to change the filtering that is done.
Type and Usage
Parameters
Takes two required and one optional parameter:
-
The first parameter is the string to encode.
-
The second parameter is the rule to apply when encoding HTML constructs. The following values are allowed:
-
none
: no conversion is done to HTML constructs. -
unsafe
: only well-known unsafe script tags are encoded. -
exceptsafe
: well-known safe script tags are not encoded. -
lfexceptsafe
: recommended for use when extended comments are entered by users and line breaks in the original text must be preserved.
-
-
An optional parameter is also available that specifies if long strings without space characters are to be broken up and what maximum word size to apply. Specify either
wordbreak
ornowordbreak
.
Output
Returns the encoded string.
See Also
-
HtmlDataInputFilterLevel in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.67 entryCount
Retrieves the number of times the current workflow step has been entered by the current revision.
-
This variable can be used to create conditional statements, but it should not be hard-coded or altered.
-
This variable is localized in the companion file and maintained in the key:
<step_name>@<workflow_name>.entryCount
Type and Usage
Output
Returns the entry count as an integer.
Example
The following code defines a jump called MaxEntry
, which exits to the parent workflow and notifies the reviewers if the last time the step was entered was more than one week ago:
<$if wfCurrentGet("entryCount")==2$>
<$wfSet("WfJumpName","MaxEntry")$>
<$wfSet("WfJumpTargetStep",wfExit(0,0))$>
<$wfSet("WfJumpEntryNotifyOff","0")$>
<$endif$>
A.68 eval()
Evaluates a variable definition as if it were Idoc Script. Can be used to recursively evaluate a literal string.
Type and Usage
Parameters
The only parameter is a variable that defines a string to be evaluated as Idoc Script.
Output
Returns the parameter string, with any Idoc Script in the variable definition resolved.
Example
Variable one is assigned the string CompanyName
, and variable two is assigned a string that includes variable one within Idoc Script delimiters. On a page, variable one presents the string CompanyName
, variable two presents the string Welcome to <$one$>
and eval(two)
presents the string Welcome to CompanyName
.
<$one="CompanyName"$> <$two="Welcome to <$one$>"$> <$one$><br> <$two$><br> <$eval(two)$>
Say you wanted to exclude all metadata fields that have the prefix xPrefix
in their names. You could use the eval()
function to dynamically write and evaluate Idoc Script for this purpose:
<$loop DocMetaDefinition$> <$if strIndexOf("xPrefix", dName) >= 0$> <$myScript = "<$" & dName & ":isExcluded=1$>"$> <$eval(myScript)$> <$endif$> <$endloop$>
A.69 ExclusiveCheckout
Determines whether users can check out content that was authored by another user.
-
When set to
TRUE
, only the author or a user with Admin permission to the security group can check out a content item. -
When set to
FALSE
, users with Write permission to the security group can check out content that was authored by another user. -
Default is
FALSE
.
Type and Usage
Location
-
System Properties, Content Security tab, Allow only original contributor to check out
-
Administration, Admin Server, Content Security menu option, Allow only original contributor to check out
-
IntradocDir
/config/config.cfg
Example
As a configuration setting, only original contributor can check out a content item.
ExclusiveCheckout=true
As Idoc Script, returns the value of the configuration setting:
<$ExclusiveCheckout$>
See Also
A.70 exec
Executes an Idoc Script expression and suppresses the output (does not display the expression on the page).
-
In earlier versions of Idoc Script, the
exec
keyword was required to suppress the value of any variable from appearing in the output file. In the current version, theexec
keyword is needed only to suppress an expression from appearing in the output.The first line in the following example is equivalent to the last two lines:
<$varA="stringA", varB ="stringB"$> <$exec varA="stringA"$> <$exec varB="stringB"$>
-
The
exec
keyword is typically used to evaluate behind-the-scenes code, such as specification of an include to be used later in the page.
Type and Usage
Parameters
The only parameter is an Idoc Script expression.
Output
Returns the value of the expression, but does not display the expression on the page.
Example
Evaluates the inc
global function to incorporate the specified includes without displaying their code on the page:
<@dynamichtml std_definitions@> <$exec inc("std_page_variable_definitions")$> <$exec inc("define_image_files")$> <@end@>
See Also
A.71 executeService()
Executes a Content Server service.
-
This function allows the specified service to be executed while the page is being constructed. Generally, services are executed using a tool such as IdcCommand or the CGI URL on the browser.
-
Used with dynamic server pages.
-
Services that can be called with the
executeService
function must be scriptable, meaning that they do not require parameter input. Scriptable services have an access level of 32 or more.
Type and Usage
Parameters
The only parameter is the name of the service to be executed. The live data in the DataBinder is used as parameters to the specified service.
Output
-
Returns a StatusCode value of
0
if the service was executed successfully. -
Returns a StatusCode value of
-1
if an error in the service execution occurred. -
All output of the executed service is suppressed, but any ResultSets and loaded values are available.
Example
Executes a service when given a service name:
<$executeService("servicename")$>
See Also
A.72 ExternalUserAccounts
Retrieves the default roles for users who are defined by an external user base (NTLM, Active Directory, or LDAP).
Type and Usage
Output
-
Returns a comma-delimited list of accounts, with permissions for each account specified in parentheses after the account name.
-
The
#none
entry grants privileges to content items that have no account assigned. The#all
entry grants privileges to all accounts.
Example
As script, returns the default account information as a string:
<$ExternalUserAccounts$>
See Also
-
“DefaultNetworkAccounts" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.73 ExternalUserRoles
Retrieves the default roles for users who are defined by an external user base (NTLM, Active Directory, or LDAP).
Type and Usage
Output
-
Returns the list of roles as a string.
Example
As script, returns the default role information as a string:
<$ExternalUserRoles$>
See Also
A.74 fieldCaption
Specifies the caption label for a metadata field.
Type and Usage
Output
Returns the caption of the metadata field as a string.
Example
Defines the caption for the dDocTitle
metadata field as the wwTitle
localized string:
<$fieldName = "dDocTitle", fieldCaption = lc("wwTitle"), isRequired = 1, fieldType = "BigText", requiredMsg = lc("wwSpecifyTitle")$>
A.75 fieldCaptionInclude
Specifies the include to use to display the caption for the metadata field.
Type and Usage
Output
None.
Example
Sets the caption display include to std_field_caption
:
<$fieldCaptionInclude = "std_field_caption"$>
A.76 fieldCaptionStyle
Specifies the style of the caption for the metadata field.
The following SPAN styles are typically used for captions. They are defined in the std_style_declaration
include in the IdcHomeDir
/resources/core/std_page.htm
resource file:
-
searchLabel
-
infoLabel
-
tableEntry
-
requiredField
Type and Usage
Output
Returns the name of the caption style.
Example
Sets the caption style to requiredField
:
<$if isRequired and not suppressCaptionHighlighting$> <$fieldCaptionStyle = "requiredField"$> <$endif$> Generates the standard field caption: <@dynamichtml std_field_caption@> <span class=<$fieldCaptionStyle$>><$fieldCaption$><$if not isFormSubmit$><$":"$><$endif$></span> <@end@>
See Also
-
“NotationForRequiredFields" and “StyleForRequiredFields" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.77 fieldDefault
Specifies the default value for a metadata field.
Type and Usage
Output
Returns the default value of the metadata field as a string.
Example
Defines the default value for the dDocTitle
metadata field:
<$fieldName = "dDocTitle", fieldCaption = lc("wwTitle"), isRequired = 1,
fieldType = "BigText", requiredMsg = lc("wwSpecifyTitle"),
fieldDefault="Enter a Title"$>
A.78 fieldEditWidth
Specifies the character width of the metadata input field on the HTML page. It is set in compute_namevalue_edit_widths
, which is included in the resource compute_std_field_includes
.
Type and Usage
Output
None.
A.79 fieldEntryInclude
Specifies the include to use to display the value for the metadata field.
Type and Usage
Example
Sets the value display include to std_checkbox_entry
:
<$fieldEntryInclude = "std_checkbox_entry"$>
A.80 fieldExtraScriptInclude
Specifies the name of the include file containing additional JavaScript validation for a specific metadata field. This is set in the resource compute_std_field_includes
.
Type and Usage
A.81 fieldInclude
Specifies the name of the include to display a metadata field. The include file is usually std_namevalue_field
, but it can be set to another include.
This is usually set at the top of the page with xFieldName:include
but can also be set by overriding the resource compute_std_field_includes
.
Type and Usage
A.82 fieldIsOptionList
Specifies whether a metadata field has an option list.
-
When set to
TRUE
, the field has an option list. -
When set to
FALSE
, the field does not have an option list. -
Default is
FALSE
.
Type and Usage
Output
-
Returns
TRUE
if the field has an option list. -
Returns
FALSE
if the field does not have an option list.
Example
Defines the dDocAccount
metadata field as an option list if predefined accounts exist:
<$if HasPredefinedAccounts$>
<$fieldIsOptionList = 1, optionListName = "docAccounts",
fieldOptionListType = "combo"$>
<$endif$>
A.83 fieldMaxLength
Specifies the maximum length of the metadata field. This is not the size of the field but the maximum number of characters that the field can contain. It is usually set at the top of the page with xFieldName:include
but can also be set by overriding the resource compute_std_field_includes
.
Type and Usage
A.84 fieldName
Specifies the internal name of a metadata field.
-
Predefined metadata fields begin with a lowercase
d
(for example,dDocName
). -
Custom metadata fields begin with a lowercase
x
(for example,xComments
).
Type and Usage
Output
Returns the name of the metadata field as a string.
Example
Defines the dDocTitle
metadata field:
<$fieldName = "dDocTitle", fieldCaption = lc("wwTitle"), isRequired = 1, fieldType = "BigText", requiredMsg = lc("wwSpecifyTitle")$>
A.85 fieldOptionListType
Specifies the type of option list for a metadata field.
Possible values for this variable follow.
fieldOptionListType Value | Corresponding Option in Configuration Manager |
---|---|
|
Select List Validated or Select List Not Validated |
|
Edit and Select List |
|
Edit and Multiselect List |
|
None used in Collaboration Server for member access lists) |
Type and Usage
Output
Returns the option list type as a string.
Example
Defines the dDocAccount
option list type as combo
(Edit and Select List):
<$if HasPredefinedAccounts$>
<$fieldIsOptionList = 1, optionListName = "docAccounts",
fieldOptionListType = "combo"$>
<$endif$>
See Also
A.86 fieldType
Specifies the type of metadata field.
Possible values for this variable follow.
fieldType Value | Corresponding Option in Configuration Manager |
---|---|
|
Text |
|
Long Text |
|
Integer |
|
Date |
|
Memo |
Type and Usage
Output
Returns the metadata field type as a string.
Example
Defines the dDocTitle
metadata field as a BigText
(Long Text) field:
<$fieldName = "dDocTitle", fieldCaption = lc("wwTitle"), isRequired = 1,
fieldType = "BigText", requiredMsg = lc("wwSpecifyTitle")$>
A.87 fieldValue
Specifies the value for a metadata field.
Type and Usage
Output
Returns the value of the current metadata field.
Example
Generates the standard field value:
<@dynamichtml std_value_label@> <span class="<$fieldValueStyle$>"><$fieldValue$></span><!--""--> <@end@>
A.88 fieldValueStyle
Specifies the style of the value for the metadata field.
The following SPAN styles are typically used for values. They are defined in the std_style_declaration
include in the IdcHomeDir
/resources/core/std_page.htm
resource file:
-
tableEntry
-
xxsmall
-
strongHighlight
Type and Usage
Output
Returns the name of the value style.
Example
Sets the value style:
<$if isFieldInfoOnly$> <$if valueStyle$> <$fieldValueStyle = valueStyle$> <$else$> <$fieldValueStyle = "tableEntry"$> <$endif$> <$endif$>
Generates the standard field value:
<@dynamichtml std_value_label@> <span class="<$fieldValueStyle$>"><$fieldValue$></span><!--'"--> <@end@>
See Also
A.89 fieldWidth
Specifies the width of a metadata field, in characters.
Type and Usage
Output
Returns the width of the current metadata field.
Example
Generates the Extension
field with a width of 10 characters:
<$fieldName = "dExtension", fieldCaption = lc("wwNativeExtension"), fieldWidth = 10$>
See Also
A.90 fileUrl
Retrieves the relative URL of the current dynamic server page (HCSP or HCST).
This variable is typically used in self-referencing pages, such as a form that posts back to itself.
Type and Usage
Output
Returns the URL as a string.
Example
Returns the relative URL of the current dynamic server page:
<$fileUrl$>
A.91 FIRSTREV
Returns the first revision label for the current revision label sequence.
Type and Usage
Output
Returns the first revision label as a string.
Example
Returns the first revision label (default is 1
):
<$FIRSTREV$>
A.92 ForcedConversionRules
Defines the Dynamic Converter rules that will apply forced conversions upon file checkin.
-
This is a comma-delimited list.
-
If a content item matches any of the specified conversion rules upon checkin, the file will be converted according to that rule. Each file can be converted into multiple renditions.
-
There is no default.
Note:
The forced conversion process does not apply the same Dynamic Converter template twice. For example, if you set
ForcedConversionRules=RuleA,RuleB
, but RuleA and RuleB specify the same template with a different layout, the conversion according to RuleB will not occur. (Best practice in this case would be to merge the layouts and use Idoc Script to dynamically select the appropriate layout elements.)
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
IntradocDir
/config/config.cfg
Example
Used as a configuration entry:
ForcedConversionRules=Rule1,Rule2,Rule3
See Also
-
DisableForcedConversions and rule:IsFragmentOnly in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.93 forceExpire()
This function can be used to force the cache for a particular include to expire. This is useful in the case of a change in the page display, such as adding new metadata fields, or if the user has saved a new query, or altered which links are viewable.
If the value for includeName
is null, or an empty string, then the entire cache will be eliminated. This is useful when all includes for a particular page are placed into the same cache, and need to be expired at the same time.
For more information about keywords versus functions, see Keywords Versus Functions.
Type and Usage
Parameters
Takes two required parameters and two optional parameters. For example:
forceExpire(includeName, scope [, cacheName, key])
Parameter | Description |
---|---|
|
The name of the dynamic HTML element to evaluate. |
scope |
Set to |
cacheName |
Optional: if you want to place this data into a named cache instead of the default cache. If an empty string is passed, it will cache the include into the default cache for the session. |
key |
Optional: if you do not want automatic name-scoping of your cache to prevent conflicts, you can specify a unique key here. |
Example
This can be used as a replacement for the std_page_begin
include. It will verify if the user executed one of the standard service calls to modify the links on the standard left navigation bar (saving a query, altering the portal design). If so, the cached html for the standard page begin will be invalidated. Then, the next cacheInclude
function will reevaluate the include, and place it back into the cache.
<$if strEquals(IdcService, "PNE_SAVE_QUERY") or strEquals(IdcService, "PNE_UPDATE_PORTAL_INFO")$> <$forceExpire("std_main_page_begin", "session", "", "std_main_page_begin")$> <$endif$> <$cacheInclude("std_main_page_begin", "session", 600, "", "std_main_page_begin")$>
A.94 formatDate()
Reformats a date/time to the default date/time format.
Database-formatted dates cannot be evaluated (for example, 2001-06-15).
Long-formatted dates cannot be evaluated (for example, June 15, 2001).
Type and Usage
Parameters
The only parameter is a string that specifies a date/time.
Output
-
Returns the date/time in the format used by dateCurrent (for example, 6/15/01 1:55 PM).
-
Returns null if the parameter cannot be evaluated.
-
If a time is not provided, returns a default time of 12:00 AM.
Example
The following example formats the date and time and displays it as 12/14/99 2:00 PM:
<$formatDate("12/14/1999 02:00 PM")$>
The following example formats the date, assigns the default time, and displays it as 9/15/03 12:00 AM:
<$formatDate("09/15/2003")$>
The following script formats and displays a specified date and time. Line one evaluates an alternate date and time format and assigns it to a custom variable. Line two displays this date to a user.
<$my_customDateTime = formatDate("06/14/2004 15:05:34")$> Final Approval: <$my_customDateTime$>
Output:
Final Approval: 6/14/04 3:05 PM
A.95 formatDateDatabase()
Formats the date and time in preparation for an SQL query. Long-formatted dates cannot be evaluated (for example, May 22, 2000).
Type and Usage
-
“Clustering" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content.
Parameters
The only parameter is a string or variable that specifies a date and time.
Output
-
Returns an ODBC-formatted date and time:
[ts 'yyyy-mm-dd hh:mm:ss']
-
Returns null if the parameter cannot be evaluated.
-
If a time is not provided, returns a default time of 00:00:00.
Example
Formats the current date and time for an SQL query:
<$formatDateDatabase(dateCurrent())$>
Formats the date and time and displays as 2001-03-19 15:32:00:
<$formatDateDatabase("03/19/2001 3:32 PM")$>
Formats the date and time and displays as 1999-04-03 00:00:00:
<$formatDateDatabase("4/3/99")$>
A.96 formatDateDisplay()
Reformats a date/time to a date/time format for display to the user. Uses the "Display Date Format" in System Properties to format the date.
Type and Usage
Parameters
The only parameter is a string that specifies a date/time.
Output
-
Returns the date/time in the format used.
-
Returns null if the parameter cannot be evaluated.
Example
<$formatDateDisplay$>
See Also
A.97 formatDateOnly()
Reformats a date/time to the default date format and strips out the time.
Database-formatted dates cannot be evaluated (for example, 2000-02-02).
Long-formatted dates cannot be evaluated (for example, June 12, 2001).
Type and Usage
Parameters
The only parameter is a string that specifies a date/time.
Output
-
Returns the date only in the format used by dateCurrent (for example, 7/12/00).
-
Returns null if the parameter cannot be evaluated.
Example
Returns the current date only (for example, 9/12/01):
<$formatDateOnly(dateCurrent())$>
Returns the date ten days in the future (for example, 9/22/01):
<$formatDateOnly(dateCurrent(10))$>
Formats the date and time and displays the date only as 1/17/00:
<$formatDateOnly("01/17/2000 2:00 PM")$>
This script displays the current date and a date 100 days in the future. Line one assigns the current date only to a custom variable. Line two assigns a date 100 days in the future to a second custom variable. Line three displays these dates to a user (for example, Start Date: 10/12/01 and End Date: 1/20/02):
<$my_startDate = formatDateOnly(dateCurrent())$> <$my_endDate = formatDateOnly(dateCurrent(100))$> Start Date: <$my_startDate$> and End Date: <$my_endDate$>
A.98 formatDateOnlyDisplay()
Reformats a date to a date format for display to the user. Uses the "Display Date Format" in System Properties to format the date.
Similar to formatDateDisplay but only formats the date.
Type and Usage
Parameters
The only parameter is a string that specifies a date.
Output
-
Returns the date in the format used.
-
Returns null if the parameter cannot be evaluated.
Example
<$formatDateOnlyDisplay$>
See Also
A.99 formatDateOnlyFull()
Reformats a date/time to the long date format and strips out the time. Database-formatted dates cannot be evaluated (for example, 2000-02-02).
This setting is deprecated for version 5.1 and later. Use formatDateWithPattern().
Type and Usage
Parameters
The only parameter is a string that specifies a date/time.
Output
-
Returns a long-formatted date:
month d, yyyy
-
Returns null if the parameter cannot be evaluated.
Example
Returns the current date in long format:
<$formatDateOnlyFull(dateCurrent())$>
Returns the date 365 days in the future in long format (for example, September 12, 2002):
<$formatDateOnlyFull(dateCurrent(365))$>
Formats the date only and displays as June 12, 2001:
<$formatDateOnlyFull("6/12/01 3:00 PM")$>
A.100 formatDateWithPattern()
Reformats a date/time to a specified date/time pattern.
When using this variable in a program (instead of dynamic page), add !rfc
to the end of the date pattern. This provides a date format that conforms to the rfc
standard. If !rfc
is not added, a program will try to use the locale to create the date string, but in the case of a timed update event, no locale is specified. Consequently, the output uses integers instead of strings for the day and month.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is a date string used by the Content Server instance, or a date object created with the
parseDate
ordateCurrent
functions. -
The second parameter is the date/time pattern, such as
MM/dd/yyyy
.The capital letter
Z
denotes the use of a UTC time zone for the entry. The lowercasezzzz
denotes the time offset (HHMM
) from the UTC time, preceded by a plus (+) or minus (-) sign to indicate the offset.
Output
-
Returns the date/time in the format specified by the pattern parameter.
-
Returns null if the parameter cannot be evaluated.
Example
Displays Wed, 5 Jul 2006 12:08:56 -0700
:
<$formatDateWithPattern(dateCurrent(),"EEE, d MMM yyyy HH:mm:ss zzzz")$>
Displays 2006-07-05 14:30:33Z:
<$formatDateWithPattern(dateCurrent(),"yyyy-MM-dd HH:mm:ssZ")$>
A.101 formatTimeOnly()
Reformats a date/time to the default time format and strips out the date.
Type and Usage
Parameters
The only parameter is a string or variable that specifies a date/time.
Output
-
Returns a time only in the format used by
dateCurrent
(for example,1:15 PM
). -
Returns null if the parameter cannot be evaluated.
Example
Returns the current time only:
<$formatTimeOnly(dateCurrent())$>
Formats the time only and displays as 5:00 PM:
<$formatTimeOnly("2/2/99 5:00 PM")$>
Formats the time only and displays as 6:14 PM:
<$formatTimeOnly("04/21/2001 18:14:00")$>
A.102 formatTimeOnlyDisplay()
Reformats a time to a time format for display to the user. Uses the "Display Date Format" in System Properties to format the time.
Similar to formatDateDisplay but only formats the time.
Type and Usage
Parameters
The only parameter is a string that specifies the time.
Output
-
Returns the time in the format used.
-
Returns null if the parameter cannot be evaluated.
Example
<$formatTimeOnlyDisplay$>
See Also
A.103 GATEWAY_INTERFACE
Retrieves the revision level of the CGI specification to which this server complies. This variable is not request-specific; it is set for all requests.
Type and Usage
Output
Returns the revision level as a string in the format CGI/revision
.
Example
As information output on a page or to a log:
GATEWAY_INTERFACE=CGI/1.1
As part of an Idoc Script statement or evaluation:
<$if GATEWAY_INTERFACE$> <!--statement-->
A.104 generateUniqueId
This function returns the unique ID for an HTML page. This is used with the id
attribute in an HTML element to guarantee a unique ID.
Type and Usage
Parameters
The only parameter is the field name for which the ID will be generated.
Output
Returns the ID for an HTML page.
A.105 getCookie
Obtains a cookie from a browser.
This is useful for tracking user sessions when the information does not need to be stored in the personalization.
Can be used to track the last pages navigated to, or the last searches which were run.
Type and Usage
Parameters
Takes one parameter, the name of the cookie.
Example
<$myCounter=getCookie("myCounter")$> <$if not myCounter$> <$myCounter=1$> <$endif$> Num times loaded: <$myCounter$> <$setCookie("myCounter", myCounter+1, dateCurrent(1))$>
See Also
A.106 GetCopyAccess
Determines what permission a user must have to get a copy of a content item.
When set to TRUE
, users can get a copy of a content item for which they have only Read permission.
When set to FALSE
, users must have Write permission to a content item to be able to get a copy.
Default is FALSE
.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Content Security tab, Allow get copy for user with read privilege
-
Administration, Admin Server, Content Security menu option, Allow get copy for user with read privilege
-
IntradocDir
/config/config.cfg
Example
As a configuration setting:
GetCopyAccess=true
As Idoc Script, returns the value of the configuration setting:
<$GetCopyAccess$>
A.107 getDebugTrace()
Retrieves the output of the debug trace.
Type and Usage
Output
-
Returns the output of the accumulated debug trace for the page being constructed.
-
Returns an empty string if
IsPageDebug
has not been set.
Example
Retrieves the output of the debug trace and outputs the information to a page:
<$getDebugTrace()$>
See Also
A.108 getErrorTrace()
Retrieves the output of the error trace.
Error trace output is encoded for display in HTML pages. For example, the < and > delimiters are HTML-escaped, and carriage returns are converted to <br> tags.
Type and Usage
Output
-
Returns the output of the accumulated error trace for the page being constructed.
-
The function returns an empty string if
IsPageDebug
has not been set.
Example
Retrieves the output of the error trace and outputs the information to a page:
<$getErrorTrace()$>
See Also
A.109 getFieldConfigValue
This function returns a configuration flag for a specific field. If the field does not exist, the default is returned instead.
Type and Usage
Parameters
Takes three parameters:
-
The name of a metadata field.
-
The flag to return for the field when it is found.
-
A default value to return if the field does not exist.
Output
Returns the specified configuration flag.
Example
<$caption = getFieldConfigValue("dDocTitle", "fieldCaption", lc("wwTitle"))$>
A.110 getFieldViewDisplayValue()
Returns the display value for an item in a Schema option list.
For example, assume an option list exists for a custom metadata field named Customer
. In the database there is a schema table with the CustomerName
column and a unique CustomerID
column. On checkin the CustomerName
value is visible to the user, but the CustomerID
value is stored in the database. The getFieldViewDisplayValue
function extracts the human-readable CustomerName
value based on the CustomerID
value.
Type and Usage
Parameters
Takes three parameters:
-
The first parameter is the name of the field to be used for the option list.
-
The second parameter is the name of the schema view used for the current field.
-
The third parameter is the value assigned to the field.
Output
Returns the display value.
Example
<$customerName = getFieldViewDisplayValue("xCustomer", "Customer_View", "1234")$>
A.111 getFieldViewValue()
This function is used when defining a content rule for a field. The value of a field for a content profile can be made dependent on a view by using this function. Because a field can have both a default and a derived value, the view can be used to create an interdependency between fields.
Type and Usage
Parameters
Takes three parameters:
-
Field. The name of a metadata field. This field must have an associated view.
-
Value. A lookup key for value.
-
Column name. A column in the view's table.
Output
Returns the value in the column specified using the field value as a lookup.
Example
In the following example, the view table for the field xEmployee
has a column called type
. Using the value as specified in the xEmployee
metadata field, this function provides a lookup into this table and returns the type
column value.
getFieldViewValue("xEmployee", #active.xEmployee, "type")
A.112 getFreeMemory()
This function returns the amount of free memory in the Java Virtual Machine (JVM). This is a performance auditing function used on the System Audit Information page.
Type and Usage
Output
The amount of free JVM memory in megabytes.
Example
<$freeMem = getFreeMemory()$>
See Also
A.113 getHelpPage
This function returns a relative URL to a help page based on the name of the page.
Type and Usage
Parameters
The name of the page used.
Example
<input type=Button value="<$lc("wwQuickHelp")$>" onClick="QuickHelp('<$getHelpPage("QH_AdvancedSearch")$>', 'Search')">
A.114 getOptionListSize
This function returns the size of an option list. It is used to determine whether to display custom user metadata fields on the User Profile page.
Type and Usage
Parameters
The only parameter is the option list to be sized.
Output
Returns the size of the specified option list.
A.115 getParentValue()
This function returns a parent value from a Schema view. This is needed before generating the dependent option list for the current field.
In most cases this function returns the same value as the internal parent value parameter because most option lists trigger their dependency on the unique key for the parent field. However, this is not a requirement for complex dependent choice lists.
Type and Usage
Parameters
Takes four parameters:
-
The name of the schema view used for the current field.
-
The name of the schema relation between this field and the parent field.
-
The name of the parent field.
-
The internal value for the parent field. This may be different than the value displayed on the page. This is often a unique number stored internally.
Example
<$parentValue=getParentValue("xState", "Country_State", "xCountry", "123")$>
A.116 getRequiredMsg()
This function is used on presentation pages to populate the Java script with the desired error message. The error message is set from the content rule user interface for a field that is designated as required. It returns a required message based on the following algorithm:
-
The function looks for the
fieldname:requiredMsg
value. -
If the value exists, it is localized.
-
If the value is undefined or the message is empty, the function returns the default message and does not localize it. To localize the message, the caller of the function must use the
lc
function on the default message before passing it to this function (getRequiredMsg
).
Type and Usage
Parameters
Takes two parameters:
-
Fieldname
: Field associated with the error message. -
Message
: Default message to be used.
See Also
A.117 getTextFile()
Gets the web version of a text file and returns its contents to a string.
-
This can be used only with files that have a format containing text, such as
text/html
,text/plain
, ortext/xml
. Specifically, thedFormat
field of the content item must start withtext
. For example, if an HCSP file is checked in, Formats:text/hcsp
is displayed in theContent Info
display; therefore, the content is displayed by thegetTextFile()
function. -
There must be enough information to determine the content item's web URL. The
dID
value is the only required metadata field.The following information must be present:
-
dDocName
,dWebExtension
,dSecurityGroup
,dRevLabel
, anddDocType
. -
If Accounts are enabled,
dDocAccount
must also be specified.
This information is available automatically after a
GET_SEARCH_RESULTS
call or after aDOC_INFO
call. -
-
This function should be wrapped with a
cacheInclude
call for greater performance. That can, however, create a security issue if all docs go to the same cache.
Type and Usage
Parameters
This function does not take parameters but uses variables on the page to determine the document's URL.
Example
<$loop SearchResults$> <$fullDocument=getTextFile()$> <h2><$dDocTitle$></h2> <div><$fullDocument$></div> <$endloop$>
See Also
A.118 getTotalMemory()
This function returns the amount of total memory in the Java Virtual Machine (JVM). This is a performance auditing function used on the System Audit Information page to determine how much memory the server is using.
Type and Usage
Output
The total JVM memory in megabytes.
Example
<$totalMem = getTotalMemory()$>
See Also
A.119 getUserValue()
Retrieves the value of a user metadata field for the current user.
The parameter must refer to a column in the Users
database table. Unlike the user personalization functions that have no support for global reference, information assigned to the user in the Users
table can be available to the Content Server instance.
Type and Usage
Parameters
The only parameter is a user-related variable.
Output
-
Returns the value of the metadata field for the current user.
-
Evaluates to
TRUE
if the user value was retrieved. -
Evaluates to
FALSE
if an error in retrieval occurred. -
Returns a StatusCode value of
-1
if the value is unspecified or unknown.
Example
Returns the user type of the currently logged on user:
<$getUserValue('dUserType')$>
A.120 getValue()
This function has multiple uses:
-
Retrieves the value of a particular metadata field from local, active, or environment data.
-
Retrieves the value of a particular column from a specific ResultSet.
-
Retrieves information about ResultSet rows.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is either the type of data or the name of a ResultSet.
-
The second parameter is the name of a metadata field, the column name, or a ResultSet row parameter.
Variations
You can also use a shorthand format that returns results identical to the getValue(arg1,arg2)
function. The format uses the form <$arg1.arg2$>
, where arg1
and arg2
are the literal string arguments "arg1
" and "arg2
" to the getValue
function.
Note:
Data types (local
, active
, and env
) and ResultSet parameters must start with the crosshatch (#
) symbol.
The following parameter combinations can be used.
getValue and Shorthand Formats | Description |
---|---|
|
Retrieves the value of the specified metadata field from the local data. |
|
Attempts to retrieve the value of the specified metadata field from the data in the following order:
|
|
Retrieves the value of the specified metadata field from the environment settings. |
|
Retrieves the value of the specified metadata field from the current row of the specified ResultSet. |
|
Retrieves the value of the specified column from the current row of the specified ResultSet. |
|
Retrieves the value of the specified column from the current row of the current ResultSet. |
|
Retrieves the number of the current row in the specified ResultSet. The first row is 0. |
|
Retrieves the total number of rows in the specified ResultSet. |
|
Checks if at least one row is present in the specified ResultSet. This is useful when looping manually with rsNext. |
|
Checks if the specified ResultSet does not contain any rows. |
Output
-
For output values, see the preceding subsection, Variations.
-
Returns an empty string if a value is not found.
Example
-
Gets the content ID from the ResultSet named
DOC_INFO
:<$name = getValue("DOC_INFO","dDocName")$>
or
<$name = <$DOC_INFO.dDocName$>
-
Checks to see if the passed parameter
dDocType
(which is in the local data) equals the value in the active ResultSet:<$loop DocTypes$> <$if strEquals(#active.dDocType, getValue("#local","dDocType"))$> <!--do special HTML for selected document type--> <$endif$> <!-- additional statement--> <$endloop$>
See Also
A.121 getValueForSpecifiedUser()
Retrieves the value of a user attribute for a specific user. This function can be useful for defining extended workflow functionality.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is the user name.
-
The second parameter is the name of a column in the
Users
database table that specifies a user attribute (such asdFullName
,dUserType
, ordEmail
).
Output
-
Returns the value of the user attribute for the specified user.
-
Returns an empty string if the value is not found.
Example
Retrieves the full name for mjones.
<$getValueForSpecifiedUser('mjones', 'dFullName')$>
A.122 getViewValue()
Returns the display value for an item in a Schema option list.
For example, assume an option list exists for a custom metadata field named Customer
. In the database there is a schema table with the CustomerName
and a unique CustomerID
. On checkin the CustomerName
is visible to the user but the CustomerID
is what is stored in the database. The getFieldViewDisplayValue
function extracts the human-readable CustomerName
based on the CustomerID
.
Type and Usage
Parameters
This function takes three parameters:
-
The name of the schema view used for the current field.
-
The value stored in the database for the ID.
-
The column name associated with the view.
Output
Returns the display value.
Example
<$custName = getViewValue("Customer_View", "1234", "CustomerName")$> <$custRegion = getViewValue("Customer_View", "1234", "CustomerRegion")$>
See Also
A.123 getViewValueResultSet()
This function loads a schema table and places it on the page as a ResultSet named SchemaData. The column names in the ResultSet are the same as the names in the database table.
This function is most useful to obtain a list of dependent choices based on a parent value.
Type and Usage
Parameters
Takes three parameters:
-
The name of the schema view used.
-
The relation for the schema and the view.
-
The value for the schema parent.
Example
Assume you have a schema table and view for a list of countries. The view is named Country_view
.
To output the contents of that table to the page, use the following code.
<$getViewValuesResultSet("Country_View", "", "")$>
<$loop SchemaData$>
<$count = 0, num = rsNumFields("SchemaData")$>
<$loopwhile count < num$>
<$fieldName=rsFieldByIndex("SchemaData", count)$>
<$fieldName$> = <$getValue("SchemaData", fieldName)$>
<$count = count + 1$>
<$endloop$>
<$endloop$>
This will output the table even if you do not know the column name.
In the following example, assume you have a DCL for the fields Country
and State
. The list of States
depends on which Country
is selected. To obtain the list of States
when the Country
is US, use this code:
<$getViewValuesResultSet("State_View", "Country_State", "US")$>
A.124 hasAppRights()
Checks if the current user has rights to an administrative application.
Type and Usage
Parameters
The only parameter is one of the following administrative applications:
-
UserAdmin
-
WebLayout
-
RepoMan
-
Workflow
-
ConfigMan
-
Archiver
Output
-
Returns
TRUE
if the user has rights to the specified application. -
Returns
FALSE
if the user does not have rights to the specified application. -
Returns a StatusCode value of
-1
if the value is unspecified or unknown.
Example
Evaluates whether the current user has rights to the specified application.
<$hasAppRights('RepoMan')$>
A.125 HasExternalUsers
Indicates to Content Server that an external user database is present.
When set to TRUE
, the system recognizes external users. If a custom component has been written to support an external user integration (such as LDAP), this should be set to TRUE
.
Default is FALSE
.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
IntradocDir
/config/config.cfg
Example
As a configuration setting:
HasExternalUsers=true
As Idoc Script, returns the value of the configuration setting:
<$HasExternalUsers$>
See Also
-
NtlmSecurityEnabled in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.126 HasLocalCopy
Checks whether the client computer has a copy of the requested content item in the download target directory.
Generally used to query the user whether to overwrite when downloading. For example, this variable is used by the Oracle ODMA Client.
Type and Usage
Output
-
Returns
TRUE
if a local copy is detected. -
Returns
FALSE
if a local copy is not detected.
Example
Checks for a local copy of the content item:
<$HasLocalCopy$>
See Also
A.127 hasOptionList
Specifies that the metadata field has an option list.
Type and Usage
Output
-
Returns
TRUE
if the field has an option list. -
Returns
FALSE
if the field does not have an option list.
Example
Specifies that the field has an option list:
<$hasOptionList=1$>
Generates the option list values if the field has an option list:
<$if hasOptionList$> <$if isQuery$></td><td><$endif$> <$include std_option_list_entry$> <$endif$>
See Also
A.128 HasOriginal
Checks if an original file exists for a revision.
This variable checks for a dOriginalName
value.
It is possible for a content item to be checked in but to not have an original file (for example, when a Basic workflow has been started but files have not been checked in at the initial contribution step).
Type and Usage
Output
-
Returns
TRUE
if an original file exists. -
Returns
FALSE
if no original file exists.
Example
Checks for an original file:
<$if HasOriginal and not isNew$>
A.129 HasPredefinedAccounts
Checks if the current user has permission to any predefined accounts. Predefined accounts are those that are created in the User Admin utility.
Type and Usage
Output
-
Returns
TRUE
if the user is assigned to any predefined accounts. -
Returns
FALSE
if the user is not assigned to any predefined accounts.
Example
Displays the Accounts option list if the user is assigned to any predefined accounts:
<$if HasPredefinedAccounts$> <$fieldIsOptionList = 1, optionListName = "docAccounts", fieldOptionListType = "combo"$> <$endif$>
A.130 HasUrl
Checks if a file exists in the weblayout
directory for the current content item.
Type and Usage
Output
-
Returns
TRUE
if aweblayout
file exists. -
Returns
FALSE
if noweblayout
file exists.
Example
Checks for a weblayout
file:
<$if HasUrl$> <$include doc_url_field$> <$endif$>
A.131 HeavyClient
Checks if the checkin is through the Content Server ODMA client or Upload applet.
Type and Usage
Output
-
Returns
TRUE
if the ODMA client orUpload
applet is being used for checkin. -
Returns
FALSE
if the ODMA client andUpload
applet are not being used for checkin.
Example
Checks for check in method:
<$HeavyClient$>
A.132 HelpDir
Defines the path to the directory that contains the online help files.
This path can be set separately for the Content Server instance and the Oracle WebCenter Content: Inbound Refinery instance.
Returns the path as a string.
Default for the Content Server instance is install_dir/weblayout/help
.
The default for Inbound Refinery is SharedDir/help
.
Type and Usage
Location
-
Content Server: IntradocDir
/config/config.cfg
-
Inbound Refinery: install_dir/IdcRefinery/shared/idcrefinery.cfg
Example
Used as a configuration entry for the Content Server instance:
HelpDir=c:/stellent/weblayout/help/
Used as a configuration entry for the Inbound Refinery instance:
HelpDir=c:/stellent/IdcRefinery/shared/help/
A.133 htmlRefreshTimeout
Similar to DefaultHtmlRefreshTimeoutInSeconds
. Defines the time, in seconds, that a Work In Progress page, My Checked-Out Content page or My Workflow Assignments page refreshes.
htmlRefreshTimeout
can be set in the URL or the service's databinder. This can be used to set a different refresh time for different pages. If that is needed, do not set DefaultHtmlRefreshTimeoutInSeconds
in the config.cfg
file, but instead set htmlRefreshTimeout
in the URL or databinder.
Type and Usage
Example
In the page's URL:
&htmlRefreshTimeout=90
See Also
-
“DefaultHtmlRefreshTimeoutInSeconds" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.134 htmlRefreshUrl
Used to set the URL of the page to load after a Work In Progress page, My Checked-Out Content page or My Workflow Assignments page is refreshed. The default is the current page. This variable can be set in the URL of the page or the databinder of the service.
Type and Usage
Example
In the page's URL:
&htmlRefreshUrl=http://www.home.com
See Also
-
DefaultHtmlRefreshTimeoutInSeconds in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.135 HttpAbsoluteCgiPath
Retrieves the Content Server CGI path as a complete URL.
This variable cannot be modified directly; to change the path, use the HttpAbsoluteCgiRoot configuration setting, described in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content.
Type and Usage
Output
Returns the path as a string.
Example
Returned for a Content Server domain:
HttpAbsoluteCgiPath=http://localhost/domain/idcplg/
(or returned for a master Content Server domain)
Returned for a proxied Content Server instance (stellent_2):
HttpAbsoluteCgiPath=http://localhost/stellent/idcplg/stellent_2/pxs
See Also
-
HttpAbsoluteCgiRoot in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.136 HttpAdminCgiPath
Retrieves the Content Server CGI path as a relative URL.
Type and Usage
Output
Returns the Content Server CGI path as a string.
Example
Returned for a Content Server instance:
HttpAdminCgiPath=/idcplg/idc_cgi_isapi-instance.dll/cs-admin/pxs
(returned for a master or proxied Content Server instance)
A.137 HttpBrowserFullCgiPath
This variable is used to set explicit control over the CGI path construction made for applets and the Content Server instance.
Content Server evaluates the HTTP address in the address bar of the browser. If the HttpIgnoreWebServerInternalPortNumber
configuration entry is not sufficient to assist the evaluation, HttpBrowserFullCgiPath
can be set with an explicit answer.
Specify a relative path to the Content Server instance (idc1
in the example that follows).
Type and Usage
Example
HttpBrowserFullCgiPath=http://localhost/idc1/idcplg
See Also
-
HttpIgnoreWebServerInternalPortNumber in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.138 HttpCgiPath
Retrieves the Content Server CGI path.
The following configuration settings are used to determine the value of this variable.
Variable | Description |
---|---|
UseSSL |
When set to |
isAbsoluteCgi |
Defines whether the complete URL is used instead of a relative path. This is an internal flag set by the Content Server instance and is not intended for user configuration. |
Type and Usage
Output
Returns the path as a string.
Example
Returned for a Content Server instance:
HttpCgiPath=/domain/idcplg
(or returned for a master Content Server instance)
Returned for a proxied Content Server (stellent_2):
HttpCgiPath=/stellent/idcplg/stellent_2/pxs
A.139 HttpCommonRoot
Retrieves the URL of the common directory.
Multiple Content Server instances can share resources from one Content Server installation. This variable defines the URL path to the DomainHome
/ucm/cs/common/
directory of the Content Server instance whose resources are being shared. For example, the HttpCommonRoot defines the prefix to use for accessing the shared common directory where web applets are located.
Type and Usage
Output
Returns the relative URL as a string. If the URL is external, the complete URL is returned rather than the relative path.
Example
Returned for a Content Server instance:
HttpCommonRoot=/domain/common/
(returned for a master or proxied Content Server instance)
A.140 HttpEnterpriseCgiPath
Retrieves the CGI path of a Content Server instance as a relative URL.
Retrieves the CGI path of a master Content Server instance. When multiple Content Server instances share the same web login, one of them is designated as the master or enterprise server.
Type and Usage
Output
Returns the Content Server CGI path as a string.
Returns the master Content Server CGI path as a string.
Example
Returned for a Content Server instance:
HttpEnterpriseCgiPath=/idcplg/idc_cgi_isapi-instance.dll
(returned for a master or proxied Content Server)
See Also
A.141 HttpHelpRoot
Retrieves the URL of the help directory.
Multiple Content Server instances can share online help files from one Content Server installation. This variable defines the URL path to the DomainHome
/ucm/cs/weblayout/help/
directory of the Content Server instance whose help files are being shared.
Type and Usage
Output
Returns the relative URL as a string. If the URL is external, the complete URL is returned rather than the relative path.
Example
Returned for a Content Server instance:
HttpHelpRoot=/domain/help/
(returned for a master or proxied Content Server)
A.142 HttpImagesRoot
Retrieves the URL of the images directory.
Multiple Content Server instances can share user interface images from one Content Server installation. This variable defines the URL path to the DomainHome
/ucm/cs/weblayout/images/
directory of the Content Server instance whose image files are being shared.
Type and Usage
Output
Returns the relative URL as a string. If the URL is external, the complete URL is returned rather than the relative path.
Example
Returned for a Content Server:
HttpImagesRoot=/domain/images/
Returned for a master or proxied Content Server:
A.143 HttpLayoutRoot
Retrieves the URL of the folder containing the current layout files. This is useful if you have additional JavaScript resources specific to the current layout.
Type and Usage
A.144 HttpRelativeAdminRoot
Retrieves the relative URL for a Content Server instance.
Defaults to /cs-admin/
during installation.
Type and Usage
Output
Returns the relative URL as a string.
Example
Returned for a Content Server instance:
HttpRelativeAdminRoot=/cs-admin/
(returned for a master or proxied Content Server)
A.145 HttpRelativeWebRoot
Defines the web server root directory as a relative URL.
-
A relative root such as /domain/ is used rather than a full root such as http://www.mycomputer.com/domain/.
-
Returns the relative web root directory as a string.
-
There is no default value.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Internet tab, Http Relative Web Root
-
Content Server:
IntradocDir
/config/config.cfg
Example
As a configuration setting, defines the relative web root:
HttpRelativeWebRoot=/domain/
As Idoc Script, returns the relative web root as a string:
<$HttpRelativeWebRoot$>
See Also
-
HttpAbsoluteWebRoot in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.146 HttpServerAddress
Defines the web server address as a partial URL.
A partial URL such as mycomputer
is used rather than a full address such as http://www.mycomputer.com/
.
Returns the web server address as a string.
There is no default value.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Internet tab, HTTP Server Address
-
Content Server:
IntradocDir
/config/config.cfg
Example
As a configuration setting, defines the web server address:
HttpServerAddress=mycomputer
As Idoc Script, returns the web server address as a string:
<$HttpServerAddress$>
See Also
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
-
IdcCommandServerHost in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
-
IntradocServerHostName in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.147 HttpSharedRoot
Retrieves the URL path of the shared directory.
Multiple Content Server instances can share resources from one Oracle Content Server installation. This variable defines the URL path to the shared/ directory of the Content Server instance whose resource files are being shared.
Type and Usage
Output
Returns the relative URL as a string. If the URL is external, the complete URL is returned rather than the relative path.
Example
Returned for a master or proxied Content Server:
HttpSharedRoot=/domain/
A.148 HttpSystemHelpRoot
Similar to the HttpHelpRoot
variable except this variable returns the path to the help files for the default system language.
Type and Usage
Output
Returns the path to the help files.
Example
HttpSystemHelpRoot=/domain/help/
A.149 HttpWebRoot
Retrieves the URL path of the weblayout/
directory.
Multiple Content Server instances can share resources from one Content Server installation. This variable defines the URL path to the DomainHome
/ucm/cs/weblayout/
directory of the Content Server instance whose resource files are being shared.
The following configuration settings determine the value of this variable.
Variable | Description |
---|---|
UseSSL |
When set to |
isAbsoluteWeb |
Defines whether the complete URL is used instead of a relative path. This is an internal flag set by the Content Server instance and is not intended for user configuration. |
Type and Usage
Output
Returns the relative URL as a string. If the URL is external, the complete URL is returned rather than the relative path.
Example
Returned for a Content Server instance:
HttpWebRoot=/domain/
(returned for a master or proxied Content Server)
A.150 HTTP_ACCEPT
Retrieves a list of content types that the browser can accept.
Type and Usage
Output
Returns a list of content types as a comma-delimited string.
Example
As information output on a page or to a log:
HTTP_ACCEPT=text/xml,application/xml,application/xhtml+xml,text/html; q=0.9,text/plain;q=0.8,video/x-mng,image/png,image/jpeg,image/gif; q=0.2,text/css,*/*;q=0.1
As part of an Idoc Script statement or evaluation:
<$if HTTP_ACCEPT$>
<!--statement-->
A.151 HTTP_ACCEPT_ENCODING
Retrieves a list of compression encodings that the browser supports.
As of Content Server version 7.0, HTML files are compressed for delivery. GZIP compression is the default.
Type and Usage
Output
Returns a list of compression encodings as a comma-delimited string.
Example
As information output on a page or to a log:
HTTP_ACCEPT_ENCODING=gzip, deflate, compress;q=0.9
As part of an Idoc Script statement or evaluation:
<$if HTTP_ACCEPT_ENCODING$>
<!--statement-->
A.152 HTTP_ACCEPT_LANGUAGE
Retrieves a list of ISO languages that are set for the browser.
This variable might be useful for estimating which user locale to set for new or guest users.
Type and Usage
Output
Returns a list of languages as a comma-delimited string.
Example
As information output on a page or to a log:
HTTP_ACCEPT_LANGUAGE=en-us,en;q=0.50
As part of an Idoc Script statement or evaluation:
<$if HTTP_ACCEPT_LANGUAGE$>
<!--statement-->
A.153 HTTP_COOKIE
Retrieves the name/value pair of the cookie in the HTTP request header.
Type and Usage
Output
Returns a string in the format name1=string1; name2=string2
.
Example
As information output on a page or to a log:
HTTP_COOKIE=IntradocAuth=Basic; IntrdocLoginState=1
As part of an Idoc Script statement or evaluation:
<$if HTTP_COOKIE$>
<!--statement-->
A.154 HTTP_HOST
Retrieves the name of the web server.
Type and Usage
Output
Returns the web server name as a string.
Example
As information output on a page or to a log:
HTTP_HOST=centralserver
As part of an Idoc Script statement or evaluation:
<$if HTTP_HOST$>
<!--statement-->
A.155 HTTP_INTERNETUSER
Retrieves the CGI parameter that the web server security filter passes to the system so that the system can set the user.
If this variable is not set, the value of the REMOTE_USER variable is used.
If HTTP_INTERNETUSER and REMOTE_USER variables are not set, the user is anonymous.
Type and Usage
Output
Returns the user name as a string.
Example
As information output on a page or to a log:
HTTP_INTERNETUSER=admin
As part of an Idoc Script statement or evaluation:
<$if HTTP_INTERNETUSER$>
<!--statement-->
A.156 HTTP_REFERER
Retrieves the complete URL of the referenced directory on the local server.
Type and Usage
Output
Returns the complete URL as a string.
Example
As information output on a page or to a log:
HTTP_REFERER=http://centralserver/domain/
As part of an Idoc Script statement or evaluation:
<$if HTTP_REFERER$>
<!--statement-->
A.157 HTTP_USER_AGENT
Retrieves the client browser type, version number, library, and platform for which the browser is configured.
Type and Usage
Output
Returns a string in the format software/version (library) (platform)
.
Example
As information output on a page or to a log:
HTTP_USER_AGENT=Mozilla/4.7 [en] (WinNT; U)
As part of an Idoc Script statement or evaluation:
<$if HTTP_USER_AGENT$>
<!--statement-->
A.158 idocTestForInclude()
This function tests to find out if a dynamichtml resource exists.
Type and Usage
Parameters
This function has one parameter: includeName
is the name of the dynamichtml resource.
Output
If the resource exists, then it returns TRUE
.
Example
<$if idocTestForInclude("std_page_begin")$> <$include std_page_begin$><$endif$>
A.159 inc()
Adds the code from an include resource to the page.
This function does the same thing as the include
keyword, except that it can take an Idoc Script variable as the parameter. For more information, see Keywords Versus Functions.
Type and Usage
Parameters
The only parameter is a variable that defines the name of an include.
Output
Displays the code that is defined in the specified include resource.
Example
Say you wanted to execute some Idoc Script for some, but not all, of your custom metadata fields. You could dynamically create includes based on the field names (such as specific_include_xComments
) by executing this Idoc Script:
<$loop DocMetaDefinition$> <$myInclude = "specific_include_" & dName$> <$exec inc(myInclude)$> <$endloop$>
Note the use of the exec
keyword, which suppresses the output of the include specified by the inc
function. If you don't use exec before the inc
function, the HTML inside the specified include will be displayed on the page.
If the specific_include_xComments
field does not exist, this code will not throw an error because the output is not being displayed.
See Also
A.160 incDynamicConversionByRule()
Returns the results of converting the LatestReleased
revision of a document using the template and layout associated with a particular Dynamic Converter conversion rule.
Fragments created through forced conversions can be referenced directly using this function.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is the content ID of a document.
-
The second parameter is the name of a conversion rule.
Output
Retrieves the specified document converted according to the template and layout defined for the specified conversion rule.
Example
Retrieves the converted rendition of the content item with a content ID of PhoneList
, converted according to conversion rule RuleA
:
<$incDynamicConversionByRule("PhoneList","RuleA")$>
See Also
A.161 incGlobal()
Includes the entire contents of a text file in the display of the current page.
This function is used to generate the default portal page.
A global include file is a text file that contains HTML code, Idoc Script code, or both. It is loaded on server startup.
Global include files must have the .inc
extension and must be located in the DomainHome
/ucm/cs/data/pages/
directory.
Type and Usage
Parameters
The only parameter is the name of a global include file without the .inc
file extension.
Output
Displays the code that is defined in the specified global include file.
Example
When you change the portal page using the Update Portal function in the Web Layout Editor, a global include file called portal_message.inc
is created to contain your modified text. This file is then referenced in the pne_home_page.htm
template file as follows:
<$incGlobal("portal_message")$>
A.162 include
Adds the code from an include resource (defined by <@dynamichtml include_name@>
) to the page.
This keyword is the most commonly used command in Idoc Script, as it allows you to reuse small chunks of code on multiple template pages.
For more information, see Includes.
Type and Usage
Parameters
The only parameter is the name of the include.
Output
Displays the code that is defined in the specified include resource.
Example
The following includes are used to create the beginning and end of most Content Server web pages. These includes are defined in the following file:
IdcHomeDir
/resources/core/standard_page.htm
<$include std_html_head_declarations$> <$include body_def$> <$include std_page_begin$> Hello World! <$include std_page_end$>
A.163 incTemplate()
Adds the contents of a Content Server template to a page, after evaluating any Idoc Script.
You can use this function to include the content of an entire template. However, this usage is discouraged because resource includes are usually sufficiently flexible to support all requirements for the sharing of Idoc Script between pages.
Type and Usage
Parameters
The only parameter is the name of a Content Server template file without the .htm
file extension.
Output
Displays the code that is defined in the specified template.
Example
Retrieves the new_look
template file.
<$incTemplate("new_look")$>
A.164 indexerSetCollectionValue()
This function modifies the logic of the search indexer. This function is designed to allow calculation of cumulative statistics about the index collection.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is the name of the flag used.
-
The second parameter is the value attributed to the flag.
Any name and value can be used. These values become available the next time the resource include is executed for the index collection.
A.165 InstanceDescription
Defines a description for the instance.
The instance description is used in the Content Server interface.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Server tab, Instance Description
-
IntradocDir
/config/config.cfg
Example
As a configuration entry:
InstanceDescription=Master_on_Server1
As Idoc Script, returns the server instance description as a string:
<$InstanceDescription$>
See Also
-
IDC_Name in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
-
InstanceMenuLabel in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.166 isActiveTrace()
Checks if a section is being traced in the core.
Type and Usage
Output
Returns active trace results.
Example
<$isActiveTrace()$>
See Also
A.167 isCheckin
Specifies if the current page is a checkin page.
When set to TRUE
, the current page is identified as a checkin page.
When set to FALSE
, the current page is not identified as a checkin page.
Type and Usage
Output
-
Returns
TRUE
if the page is a checkin page. -
Returns
FALSE
if the page is not a checkin page.
Example
Set at the top of a page:
isCheckin=1
Used as script:
<$if isCheckin or isUpdate or isQuery$> <$isFormSubmit = 1$> <$if not isQuery$> <$isEditMode = 1$> <$formName = "Checkin"$> <$endif$> <$else$> <$isFormSubmit = ""$> <$isEditMode = ""$> <$endif$>
A.168 IsCheckinPreAuthed
Checks if a checkin application preauthorized the current checkin by getting a security token.
Type and Usage
Output
-
Returns
TRUE
if the checkin is preauthorized. -
Returns
FALSE
if the checkin is not preauthorized.
Example
Checks for checkin preauthorization:
<$IsCheckinPreAuthed$>
A.169 isComponentEnabled
Checks if the defined component in enabled.
Type and Usage
Parameters
The only parameter is the component name.
Output
-
Returns
TRUE
if the defined component is enabled. -
Returns
FALSE
if the defined component is not enabled.
Example
<$isComponentEnabled("Folders")$>
A.170 IsContributor
Used to evaluate whether a user is a contributor. Generally used to determine whether to show special links on a page (for example, std_page
uses it to decide whether to display the Content Manager link).
Type and Usage
Output
-
Returns
TRUE
if the user is a contributor. -
Returns
FALSE
if the user is not a contributor.
Example
Used to evaluate whether a user is a contributor:
<$if IsContributor$>
A.171 IsCriteriaSubscription
Evaluates whether a subscription to the content item is criteria-based rather than based on the content ID (dDocName
).
Type and Usage
Output
-
Returns
TRUE
if the subscription is criteria-based. -
Returns
FALSE
if the subscription is to a particular content item.
Example
Evaluates whether subscription is criteria based:
<$IsCriteriaSubscription$>
A.172 IsCurrentNav
Checks if the page currently being displayed is the same as the page being looped over while building the Next/Previous navigation on search results pages.
Type and Usage
Output
-
Returns
TRUE
if the navigation loop is at the same page as the current page. -
Returns
FALSE
if the navigation loop is not at the same page as the current page.
Example
If the navigation loop is at the current page, the page number is displayed as plain text. If the navigation loop is not at the current page, the page number is displayed as a hypertext link:
<$loop NavigationPages$> <$if IsCurrentNav$> <$HeaderPageNumber$> <$else$> <a href="<$strRemoveWs(inc("searchapi_navigation_specific_page"))$>"> <$HeaderPageNumber$></a> <$endif$> <$endloop$>
A.173 isDocPage
Specifies if the current page is a page that displays metadata (such as search, checkin, and content information pages).
When set to TRUE
, the current page is identified as a document page.
When set to FALSE
, the current page is not identified as a document page.
Type and Usage
Output
-
Returns
TRUE
if the page is a document page. -
Returns
FALSE
if the page is not a document page.
Example
Set at the top of a page:
isDocPage=1
Used as script:
<$if isDocPage$> <!--statement--> <$endif$>
A.174 IsDynamic
Checks if the page is presented dynamically to the user.
Most pages viewed by the user are dynamic. However, some static pages are designed to be delivered to the user without changes. Examples are the guest portal page and the content of some auto generated emails.
Type and Usage
Output
-
Returns
TRUE
if the page is being presented dynamically to the user. -
Returns
FALSE
if the page is static or cannot be displayed.
Example
Evaluates whether the page is presented dynamically:
<$if IsDynamic$> <a href="<$redirect$>"> <$endif$>
A.175 IsDynamicConverterEnabled
Enables Dynamic Converter.
This value is set to FALSE
during initial WebCenter Content installation.
This value is set to TRUE
during Dynamic Converter installation.
Default is FALSE
.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Options tab, Enable Dynamic Converter
-
Administration, Admin Server, General Configuration menu option, Enable Dynamic Converter
-
IntradocDir
/config/config.cfg
Example
As a configuration setting, enables Dynamic Converter functionality:
IsDynamicConverterEnabled=true
As Idoc Script, used to evaluate whether dynamic converter functionality is enabled:
<$if IsDynamicConverterEnabled and isTrue(IsDynamicConverterEnabled)$> <tr> <td align="center" width="75"> <a href="<$HttpCgiPath$>?IdcService=GET_TEMPLATE_CONVERSIONS"> <img src="<$HttpImagesRoot$><$admin_conversion_image$>" border="0" width="<$adminImageWidth$>" height="<$adminImageHeight$>"></a> </td> <td width="10"> </td> <td width="245"><span class=largeTableEntry> <a href="<$HttpCgiPath$>?IdcService=GET_TEMPLATE_CONVERSIONS"> <$lc("wwTemplateConversions")$></span></a> </td> </tr> <$endif$>
A.176 isEditMode
Specifies if metadata fields on the current page can be edited.
This variable is set on checkin and content information update pages.
When set to TRUE
, metadata fields on the current page can be edited.
When set to FALSE
, metadata fields on the current page cannot be edited.
Type and Usage
Output
-
Returns
TRUE
if metadata fields on the current page can be edited. -
Returns
FALSE
if metadata fields on the current page cannot be edited.
Example
Set at the top of a page:
isEditMode=1
Used as script:
<$if isCheckin or isUpdate or isQuery$> <$isFormSubmit = 1$> <$if not isQuery$> <$isEditMode = 1$> <$formName = "Checkin"$> <$endif$> <$else$> <$isFormSubmit = ""$> <$isEditMode = ""$> <$endif$>
A.177 IsEditRev
Checks whether the current revision is in an Editor step in a workflow.
When set to TRUE
, reviewers can check out, edit, and check in the revision.
This variable is set by defining a workflow step as an Editor step in the Workflow Admin tool. This variable is evaluated on the checkin page.
Type and Usage
Output
-
Returns
TRUE
if the current revision is in an Editor step in a workflow. -
Returns
FALSE
if the current revision is not in an Editor step in a workflow.
Example
Provides workflow details:
<$if IsEditRev$> addCheckinValue("IdcService", "WORKFLOW_CHECKIN"); if (form.isFinished.checked) addCheckinValue("isFinished", form.isFinished.value); <$else$> addCheckinValue("IdcService", "CHECKIN_SEL"); <$endif$>
A.178 isExcluded
Completely excludes the metadata field from the page.
Type and Usage
Output
-
Returns
TRUE
if the metadata field is excluded from the page. -
Returns
FALSE
if the metadata field is not excluded from the page.
Example
Excludes the current metadata field from the page:
<$isExcluded=1$>
Sets a custom variable depending on the active value of isExcluded for the current metadata field:
<$isCustomExcluded = getValue("#active", fieldName & ":isExcluded")$> $isCustomRelocated = getValue("#active", fieldName & ":isRelocated")$> <$if isCustomExcluded or (isCustomRelocated and not isRelocated) or isExcluded or (isFieldHidden and not isFormSubmit)$> <$isFieldExcluded = 1$> <$endif$>
A.179 IsExternalUser
Checks if the user is accessing the Content Server instance from an external system, such as an LDAP system.
Or a proxied server.
Type and Usage
Output
-
Returns
TRUE
if the user is accessing the Content Server instance from an external system. -
Returns
FALSE
if the user is accessing the Content Server instance directly.
Example
Checks if user is at an external location:
<$IsExternalUser$>
A.180 IsFailedConversion
Checks if the Oracle WebCenter Content: Inbound Refinery system has failed to convert the content item.
Type and Usage
Output
-
Returns
TRUE
if the conversion process failed. -
Returns
FALSE
if no conversion failure was detected.
Example
Displays text if the conversion process was not complete:
<$if IsFailedConversion$> <p><font face="arial" size="2"> The Refinery was unable to complete the conversion process.</p> <$endif$>
A.181 IsFailedIndex
Checks if the Indexer has failed to index the content item.
Type and Usage
Output
-
Returns
TRUE
if the Indexer was unable to index the content item. -
Returns
FALSE
if the content item was indexed successfully.
Example
Displays text if the content item was not indexed:
<$if IsFailedIndex $> <p><font face="arial" size="2"> Unable to index content item.</p> <$endif$>
A.182 sawflies()
Checks if a string or expression evaluates to FALSE
.
Type and Usage
Parameters
The only parameter is the string or expression to be evaluated.
Output
If the parameter is a string:
-
Returns
TRUE
if the string begins withF
,f
,N
, orn
, or is0
. -
Returns
FALSE
if the string begins with any other character.
If the parameter is not a string:
-
Returns
TRUE
if the value is 0. -
Returns
FALSE
if the value is not 0.
Example
Evaluates the string false
and returns TRUE
(1):
<$isFalse("false")$>
Evaluates that the integer five is greater than one and returns FALSE
(0):
<$isFalse(5>1)$>
Evaluates the result of the equation as zero and returns TRUE
(1
):
<$isFalse(1-1)$>
Evaluates the string equality statement as true and returns FALSE
(0
):
<$isFalse(strEquals("abc","abc"))$>
See Also
A.183 is Field Excluded
Specifies that the metadata field is excluded.
Type and Usage
Output
-
Returns
TRUE
if the field is excluded. -
Returns
FALSE
if the field is not excluded.
Example
Determines if the metadata field is excluded:
<$if isCustomExcluded or (isCustomRelocated and not isRelocated) or isExcluded or (isFieldHidden and not isFormSubmit)$> <$isFieldExcluded = 1$> <$endif$>
A.184 isFieldHidden
Specifies that the metadata field is hidden.
Type and Usage
Output
-
Returns
TRUE
if the field is hidden. -
Returns
FALSE
if the field is not hidden.
Example
Determines if the metadata field is hidden:
<$if isHidden or isCustomHidden$> <$isFieldHidden = 1$> <$else$> <$isFieldHidden = ""$> <$endif$>
A.185 isFieldInfoOnly
Specifies that the metadata field is an information only field.
Type and Usage
Output
-
Returns
TRUE
if the field is an information only field. -
Returns
FALSE
if the field is not an information only field.
Example
Determines if the metadata field is information only:
<$if isInfo or isCustomInfo or isFieldHidden or isInfoOnly$> <$isFieldInfoOnly = 1$> <$else$> <$isFieldInfoOnly = ""$> <$endif$>
A.186 isFieldMemo
Specifies that the metadata field is a memo field.
Type and Usage
Output
-
Returns
TRUE
if the field is a memo field. -
Returns
FALSE
if the field is not a memo field.
Example
Determines if the field is a memo field:
<@dynamichtml compute_std_entry_type_info@> <$if not hasOptionList and #active.fieldType like "Memo"$> <$isFieldMemo = 1$> <$else$> <$isFieldMemo = ""$> <$endif$> <@end@>
See Also
A.187 IsFilePresent
Checks if the page currently being displayed is for the revision being looped over while building the Revision History table on a content information page.
Type and Usage
Output
-
Returns
TRUE
if the loop is at the same revision as the current revision. -
Returns
FALSE
if the loop is not at the same revision as the current revision.
Example
If the loop is at the current revision, the revision number is displayed as plain text. If the loop is not at the current revision, the revision number is displayed as an active button.
<@dynamichtml doc_rev_info@> <$if IsFilePresent$> <td width=10% align=center><span class=strongHighlight><$dRevLabel$></span></td> <td nowrap width=30%><span class=strongHighlight><$dInDate$></span></td> <td nowrap width=30%><span class=strongHighlight> <$if dOutDate$><$dOutDate$><$else$><$lc("wwNone")$><$endif$></span></td> <td width=20%><span class=strongHighlight> <$rptDisplayMapValue("StatusList", dStatus)$></span></td> <$else$> <td width=10%><form action="<$HttpCgiPath$>" method=GET> <input type=hidden name=IdcService value="DOC_INFO"> <input type=hidden name=dID value="<$dID$>"> <input type=hidden name=dDocName value="<$dDocName$>"> <input type=submit value=" <$dRevLabel$> "> </form></td> ... <@end@>
A.188 isFormSubmit
Specifies if the current page is a submittable HTML form.
When set to TRUE
, the current page is a submittable HTML form.
When set to FALSE
, the current page is not a submittable HTML form.
Type and Usage
Output
-
Returns
TRUE
if the page is a submittable HTML form. -
Returns
FALSE
if the page is not a submittable HTML form.
Example
Set at the top of a page:
isFormSubmit=1
Adds a colon after the field captions if the page is not a submittable HTML form:
<@dynamichtml std_field_caption@> <span class=<$fieldCaptionStyle$>> <$fieldCaption$><$if not isFormSubmit$><$":"$><$endif$> </span> <@end@>
A.189 IsFullTextIndexed
Checks if the Indexer has full-text indexed the content item.
Type and Usage
Output
-
Returns
TRUE
if the content item has been full-text indexed. -
Returns
FALSE
if the content item has not been full-text indexed.
Example
Provides a specified URL if the content item is full-text indexed:
<$if IsFullTextIndexed$> <a href="<$redirect$>"> <$endif$>
A.190 isHidden
Hides the metadata field from the user but includes the field as hidden data on the page.
Type and Usage
Output
-
Returns
TRUE
if the metadata field is hidden on the page. -
Returns
FALSE
if the metadata field is not hidden the page.
Example
Hides the current metadata field from the user:
<$isHidden=1$>
Sets a custom variable depending on the active value of isHidden for the current metadata field:
<$isCustomHidden = getValue("#active", fieldName & ":isHidden")$> <$if isHidden or isCustomHidden$> <$isFieldHidden = 1$> <$else$> <$isFieldHidden = ""$> <$endif$>
A.191 isInfo
Specifies if the current page is an information-only page.
When set to TRUE
, the current page is identified as an information-only page.
When set to FALSE
, the current page is not identified as an information-only page.
Type and Usage
Output
-
Returns
TRUE
if the page is an information-only page. -
Returns
FALSE
if the page is not an information-only page.
Example
Set at the top of a page:
isInfo=1
Used as script:
<$if isInfo$> <$captionFieldWidth="30%"$> <$captionEntryWidth="70%"$> <$elseif isEditMode$> <$captionFieldWidth="20%"$> <$captionEntryWidth="80%"$> <$endif$>
A.192 isInfoOnly
Displays the metadata field as information only, not as an input field.
Type and Usage
Output
-
Returns
TRUE
if the metadata field is displayed as information only. -
Returns
FALSE
if the metadata field can be edited.
Example
Displays the current metadata field as information only:
<$isInfoOnly=1$>
Sets a custom variable depending on the active value of isInfoOnly for the current metadata field:
<<$isCustomInfo = getValue("#active", fieldName & ":isInfoOnly")$> <$if isInfo or isCustomInfo or isFieldHidden or isInfoOnly$> <$isFieldInfoOnly = 1$> <$else$> <$isFieldInfoOnly = ""$> <$endif$>
A.193 IsIntranetAuthOnly
Sets the default authorization type to intranet
.
When set to TRUE, the web server filter assumes the authorization type to be intranet
. The first time a user logs in to the Content Server instance and accesses a CGI URL, NTLM security is used rather than Oracle database security.
When set to FALSE, no authorization type is assumed.
Default is FALSE.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
IntradocDir/config/config.cfg
Example
Used as a configuration entry:
IsIntranetAuthOnly=true
A.194 IsJava
Displays the local data of a Content Server web page.
This variable can be set as a flag on a page or as a parameter to a service call.
Type and Usage
Output
When set to TRUE
, returns the local data in the DataBinder, in HDA format.
Example
When included in the code on a Content Server web page, displays the local data of a page:
<$IsJava=1$>
When included in a Content Server URL, displays the local data for the New Checkin page:
http://myinstance.com/idcplg/idc_cgi_isapi-instance.dll?IdcService=CHECKIN_NEW_FORM&IsJava=1
A.195 isLayoutEnabled()
Used to determine if a particular layout is installed and enabled.
Type and Usage
Parameters
Takes one parameter, the ID of the layout.
Example
In the std_resources.htm
file:
<$if isLayoutEnabled("Trays")$><$do Publish=1$><$endif$>
A.196 isLinkActive
Used by Idoc Script to determine whether to include the profile in a display of profiles for check-in or search based on specified conditions, such as a user's name. If the specified condition or conditions evaluate to true, the value of IsLinkActive
is set to true (1
) and the profile is included in the list of available profiles.
Type and Usage
Parameters
There are no parameters, just the setting of 1
or 0
(true or false) based on the evaluated condition or conditions.
Example
Here is the default script for a condition set with a single clause. If the user name matches "guest
", then isLinkActive
is set to 1
and the profile is included in the list of available profiles for that user.
<$if getUserValue("dName") like "guest"$> <$isLinkActive=1$> <$endif$>
A.197 IsLocalSearchCollectionID
Checks if the content item is in the local search collection. Searches for the content item's content ID in the local search collection.
Type and Usage
Output
-
Returns
TRUE
if the content item is in the local collection. -
Returns
FALSE
if the content item is not found in the local collection.
Example
Evaluates whether a content item is from a local collection:
<@dynamichtml searchapi_define_result_doc_parameters@> <$exec IsLocalSearchCollection="1"$> <$if not IsLocalSearchCollectionID$> <!--Collection has external ID--> <$exec IsLocalSearchCollection=""$>
A.198 IsLoggedIn
Checks if the current user is logged in.
Type and Usage
Output
-
Returns
TRUE
if the user has logged in. -
Returns
FALSE
if the user has not logged in.
Example
Checks whether the user is logged in and has an email address before performing a function.
<@dynamichtml subscription_action_script@> function allowSubscription(form) {<$if IsLoggedIn$> <$if IsUserEmailPresent$> <$else$> …} <@end@>
A.199 IsMac
Checks if the client browser is running on a Macintosh operating system.
Type and Usage
Output
-
Returns
TRUE
if the client browser is running on a Mac. -
Returns
FALSE
if the client browser is not running on a Mac.
Example
Redirects to a different URL if the browser is running on a Mac:
<$if IsMac$> <a href="<$redirect$>"> <$endif$>
A.200 IsMaxRows
Checks if there are more results on a Work In Progress or Report page than the MaxQueryRows
setting allows. For more information, see "MaxQueryRows" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content.
Type and Usage
Output
-
Returns
TRUE
if the number of results is greater than the number of rows permitted. -
Returns
FALSE
if the number of results is less than the number of rows permitted.
Example
Returns an error message if the maximum number of rows is exceeded:
<$elseif IsMaxRows$> <table border=0 cellpadding=1 cellspacing=1 width="100%"> <tr> <span class=smallHighlight><$lc("wwOutputLimitedByMaxRows")$> </span> </tr> </table>
A.201 isMultiOption
Specifies that a metadata field option list allows multiple values to be selected.
Type and Usage
Output
-
Returns
TRUE
if the field is a multiselect option list. -
Returns
FALSE
if the field is not a multiselect option list.
Example
Specifies that the field is a multiselect option list:
<$isMultiOption=1$>
Determines the type of option list:
<$if #active.fieldOptionListType like "*multi*"$> <$exec isMultiOption=1$> <$elseif #active.fieldOptionListType like "access*"$> <$exec isAccessList=1$> <$exec isStrictList=1$> <$elseif not (#active.fieldOptionListType like "*combo*")$> <!--Strict choice--> <$exec isStrictList=1$> <$endif$>
See Also
A.202 IsMultiPage
Checks if multiple pages are needed for search results. This variable depends on the number of rows displayed per page, which is defined by the ResultCount
input variable (default is 25).
Type and Usage
Output
-
Returns
TRUE
if the number of search results is greater than the number of rows permitted per page. -
Returns
FALSE
if the number of search results is less than the number of rows permitted per page.
Example
Evaluates number of rows and determines if multiple pages are needed:
<$IsMultiPage$>
A.203 isNew
Checks if the content item is new or a revision. This variable is set to TRUE
by the CHECKIN_NEW_FORM
and CHECKIN_SIMILAR_FORM
standard services.
Type and Usage
Output
-
Returns
TRUE
if the content item is new. -
Returns
FALSE
if the content item is a revision to an existing content item.
Example
If the content item is new, a specified service is performed:
<$if isNew$> <input type=hidden name=IdcService value="CHECKIN_NEW"> <$endif$>
If the content item is a revision, the original content item author is used:
<$if not isNew$>value="<$dDocAuthor$>"<$endif$>
If the content item is new, the default accounts for the current user are used:
<$if isNew$> <$defaultAccounts$> <$endif$>
A.204 IsNotLatestRev
Checks if the revision is the last revision to be checked in. This is not necessarily the last released revision.
Type and Usage
Output
-
Returns
TRUE
if the content item is other than the latest revision to be checked in. -
Returns
FALSE
if the content item is the latest revision to be checked in.
Example
Checks for the latest revision:
<$IsNotLatestRev$>
See Also
A.205 IsNotSyncRev
Checks whether the file on the client computer matches the most current revision by performing a revision ID (dID
) comparison.
This variable is generally used to display an error message when the local copy of a content item has not been updated to the latest revision.
This variable is used to interface with client-side products, such as Desktop.
Type and Usage
Output
-
Returns
TRUE
if revisions do not match. -
Returns
FALSE
if revisions match.
Example
Checks for a match with the latest revision and displays an error message:
<$if IsNotSyncRev$> The local copy of this content item has not been updated to the latest revision. Use Get Native File or Check Out to update your local copy of <$dDocName$>. <$endif$>
A.206 IsOverrideFormat
Enables users to select a different conversion format upon checkin.
When set to TRUE
, a Format
option list is displayed for the Primary File and Alternate File on the checkin page.
Default is FALSE
.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Options tab, Allow override format on check in
-
Administration, Admin Server, General Configuration menu option, Allow override format on check in
-
IntradocDir
/config/config.cfg
Example
As a configuration setting:
IsOverrideFormat=true
As Idoc Script, returns the value of the override format function:
<$IsOverrideFormat$>
A.207 IsPageDebug
Enables a trace of all includes and calls to the Idoc Script eval
function.
The contents of the eval
function and any dynamically assigned includes are also shown as part of the trace. The trace is indented by one + character per nested level of include
or eval
call. The trace also shows any error messages (without the nested location information) and the output of any calls to the Idoc Script trace
function.
Note:
This setting is not supported in Internet Explorer version 6.
Type and Usage
Output
Results of the trace can be viewed through the debug menu toolbar options, which are accessed from the debug trace displayed at the bottom of the web page.
Click the debug trace to display the debug menu toolbar, then click any of the following options.
Element | Description |
---|---|
hide all |
Hides any open debug popups. |
idocscript trace |
Displays a tree structure view of all includes being called. |
request binder |
Displays information on Local Data and ResultSets. The request binder is the DataBinder sent to the server, that is, the service name and any service-specific parameters. Click a heading to expand the view of detailed information. |
response binder |
Displays information on Local Data and ResultSets. The response binder is the DataBinder immediately after the service is processed but before the response page is generated. Click a heading to expand the view of detailed information. |
final page binder |
Displays information on Local Data and ResultSets. The final page binder reflects what was changed in the DataBinder while the page was being generated. Click a heading to expand the view of detailed information. |
javascript log |
Displays Logger Console window with default setting of Verbose. Select checkboxes to display the following options: info, warn, error, time, window, trace, global, schema, javascript, LogReader. Click Pause or Clear to control the speed and amount of information displayed on the Logger Console. |
If you are interested in API-level interaction with Content Server, consult the request and response binders. For example, when you do a SOAP request or use other service-based APIs, the information in the final page binder is meaningless. When you append IsJava=1
to the request, the response binder in HDA format is returned.
If you are interested in customization, page generation, and so on, you may want to consult the final page binder and, in some cases, determine how it differs from the response binder.
Example
Used as a configuration setting in the Content Server config.cfg
file, so it applies to the entire server:
IsPageDebug=1
In a web browser, added to the end of the page's URL in the Address field:
&IsPageDebug=1
Used on a template page or in an Idoc Script include:
<$IsPageDebug=1$>
See Also
A.208 IsPromptingForLogin
Checks if the Content Server instance is set to prompt for login or if login is being handled programmatically.
This variable is set to TRUE
in situations such as cookie login pages, where the last request failed because the user is not logged in yet.
Type and Usage
Output
-
Returns
TRUE
if the Content Server instance is set to prompt for login. -
Returns
FALSE
if login is being handled programmatically.
Example
Evaluates if server is set to prompt for login:
<$IsPromptingForLogin$>
A.209 IsProxiedServer
Specifies that the Content Server instance is a proxied server.
When set to TRUE, the Content Server instance is a proxied server.
For a master Content Server instance, there is no default.
For a proxied Content Server instance, the default is TRUE
.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
IntradocDir/config/config.cfg
Example
Used as a configuration entry:
IsProxiedServer=true
A.210 isQuery
Specifies if the current page is a search page.
When set to TRUE
, the current page is identified as a search page.
When set to FALSE
, the current page is not identified as a search page.
Type and Usage
Output
-
Returns
TRUE
if the page is a search page. -
Returns
FALSE
if the page is not a search page.
Example
Set at the top of a page:
isQuery=1
Used as script:
<$if isCheckin or isUpdate or isQuery$> <$isFormSubmit = 1$> <$if not isQuery$> <$isEditMode = 1$> <$formName = "Checkin"$> <$endif$> <$else$> <$isFormSubmit = ""$> <$isEditMode = ""$> <$endif$>
A.211 isRelocated
Excludes the metadata field unless the local variable is set to TRUE
while the include is evaluated.
This variable is typically used to set a custom location for a metadata field. It allows a field to be defined on a page more than once, with the location of the field that is actually generated depending on the value of this variable.
Type and Usage
Output
-
Returns
TRUE
if the metadata field is included at that location on the page. -
Returns
FALSE
if the metadata field is excluded from that location on the page.
Example
Includes the current metadata field on the page:
<$isRelocated=1$>
Sets a custom variable depending on the active value of isRelocated for the current metadata field:
<$isCustomExcluded = getValue("#active", fieldName & ":isExcluded")$> <$isCustomRelocated = getValue("#active", fieldName & ":isRelocated")$> <$if isCustomExcluded or (isCustomRelocated and not isRelocated) or isExcluded or (isFieldHidden and not isFormSubmit)$> <$isFieldExcluded = 1$> <$endif$>
See Also
A.212 IsRequestError
Checks if there is a request error condition present in the Content Server instance by evaluating the StatusCode variable.
If StatusCode
is set to a negative numeric value (-1), there is a request error condition present in the Content Server instance.
The typical behavior when a request error condition is present is to abort the display of the current page and substitute an error page.
Type and Usage
Output
-
Returns
TRUE
if there is a request error condition present in the Content Server instance (StatusCode = -1
). -
Returns
FALSE
if there is no request error condition present on the Content Server instance (StatusCode
is other than a negative numeric value).
Example
Evaluates the request error condition:
<$IsRequestError$>
See Also
A.213 isRequired
Specifies if a value is required for a metadata field.
When set to TRUE
, the metadata field is required.
When set to FALSE
, the metadata field is optional.
Type and Usage
Output
-
Returns
TRUE
if the metadata field is required. -
Returns
FALSE
if the metadata field is optional.
Example
Defines the dDocTitle metadata field as a required field:
<$fieldName = "dDocTitle", fieldCaption = lc("wwTitle"), isRequired = 1,
fieldType = "BigText", requiredMsg = lc("wwSpecifyTitle")$>
See Also
A.214 IsSavedQuery
Checks if a query has been saved to the current user's portal navigation bar.
Type and Usage
Output
-
Returns
TRUE
if the current query has been saved. -
Returns
FALSE
if the current query has not been saved or no query is found.
Example
Evaluates query status:
<$IsSavedQuery$>
A.215 IsSoap
Displays the local SOAP data of a Content Server web page.
This variable can be set as a flag on a page or as a parameter to a service call.
Type and Usage
Output
When set to TRUE
, returns the underlying SOAP code, in XML format.
Example
When included in the code on a Content Server web page:
<$IsSoap=1$>
When included in a Content Server URL:
http://myinstance.com/idcplg/idc_cgi_isapi-instance.dll?IdcService=CHECKIN_NEW_FORM&IsSoap=1
A.216 isStrictList
Specifies that a metadata field option list does not allow multiple values to be selected.
Type and Usage
Output
-
Returns
TRUE
if the field is not a multiselect option list. -
Returns
FALSE
if the field is a multiselect option list.
Example
Specifies that the field is not a multiselect option list:
<$isStrictList=1$>
Determines the type of option list:
<$if #active.fieldOptionListType like "*multi*"$> <$exec isMultiOption=1$> <$elseif #active.fieldOptionListType like "access*"$> <$exec isAccessList=1$> <$exec isStrictList=1$> <$elseif not (#active.fieldOptionListType like "*combo*")$> <!--Strict choice--> <$exec isStrictList=1$> <$endif$>
See Also
A.217 IsSubAdmin
Checks if the current user has subadministrator rights to at least one administrative application.
Type and Usage
Output
-
Returns
TRUE
if the user has subadministrator rights. -
Returns
FALSE
if the user does not have subadministrator rights.
Example
Checks whether the user is logged in and has subadministrator rights before performing a function.
<@dynamichtml subscription_action_script@> function allowSubscription(form) { <$if IsLoggedIn$> <$if IsSubAdmin$> <$else$> … } <@end@>
A.218 IsSun
Checks if the client browser is running on a Sun system.
Type and Usage
Output
-
Returns
TRUE
if the client browser is running on Sun. -
Returns
FALSE
if the client browser is not running on Sun.
Example
Redirects to a different URL if the browser is running on Sun:
<$if IsSun$> <a href="<$redirect$>"> <$endif$>
A.219 IsSysManager
Checks if the current user has the sysmanager
role, meaning the user has access to Content Server administration. This variable is usually used to conditionally display specific navigation links.
Type and Usage
Output
-
Returns
TRUE
if the user has thesysmanager
role. -
Returns
FALSE
if the user does not have the role
A.220 isTrue()
Checks if a string or expression evaluates to TRUE
.
Type and Usage
Parameters
The only parameter is the string or expression to be evaluated.
Output
If the parameter is a string:
-
Returns
TRUE
if the string begins with T, t, Y, y, or is 1. -
Returns
FALSE
if the string begins with any other character.
If the parameter is not a string:
-
Returns
TRUE
if the value is not 0. -
Returns
FALSE
if the value is 0.
Example
Evaluates the string yes
and returns TRUE
(1
):
<$isTrue("yes")$>
Evaluates that the integer five is greater than one and returns TRUE
(1
):
<$isTrue(5>1)$>
Evaluates the result of the equation as zero and returns FALSE
(0
):
<$isTrue(1-1)$>
Evaluates the string equality statement as true and returns TRUE
(1
):
<$isTrue(strEquals("abc","abc"))$>
See Also
A.221 isUpdate
Specifies if the current page is a content information update page.
When set to TRUE
, the current page is identified as a content information update page.
When set to FALSE
, the current page is not identified as a content information update page.
Type and Usage
Output
-
Returns
TRUE
if the page is a content information update page. -
Returns
FALSE
if the page is not a content information update page.
Example
Set at the top of a page:
isUpdate=1
Used as script:
<$if isCheckin or isUpdate or isQuery$> <$isFormSubmit = 1$> <$if not isQuery$> <$isEditMode = 1$> <$formName = "Checkin"$> <$endif$> <$else$> <$isFormSubmit = ""$> <$isEditMode = ""$> <$endif$>
A.222 isUploadFieldScript
Specifies that an include is being used inside JavaScript. It is used to determine how metadata fields are uploaded.
When set to TRUE
, the include is being used inside JavaScript.
When set to FALSE
, the include is being used inside JavaScript.
Type and Usage
Output
-
Returns
TRUE
if the include is being used inside JavaScript. -
Returns
FALSE
if the include is not being used inside JavaScript.
Example
Set in the include that defines the JavaScript wrapper:
<@dynamichtml std_upload_java_script@> <script language="JavaScript"> // Java script for uploading. <$isUploadFieldScript = 1$> <$include std_upload_info_script$> <$isUploadFieldScript = ""$> </script> <@end@>
Used as script:
<$if isUploadFieldScript$> <$defaultFieldInclude = "std_file_entry"$> <$else$> <$defaultFieldInclude = "std_nameentry_row"$> <$fieldCaptionInclude = "std_field_caption"$> <$fieldEntryInclude = "std_file_entry"$> <$endif$>
A.223 IsUploadSockets
Used by the Upload applet to determine whether the upload socket should be used.
This is an internal flag and is not intended for user configuration.
Type and Usage
Output
-
Returns
TRUE
if the upload socket is defined for use with the Upload applet. -
Returns
FALSE
if the upload socket should not be used.
Example
N/A
A.224 IsUserEmailPresent
Checks if an email address is defined for the current user.
Type and Usage
Output
-
Returns
TRUE
if an email address is defined for the user. -
Returns
FALSE
if an email address is not defined for the user.
Example
Checks whether the user is logged in and has an email address before performing a function.
<@dynamichtml subscription_action_script@> function allowSubscription(form) { <$if IsLoggedIn$> <$if IsUserEmailPresent$> <$else$> … } <@end@>
A.225 isUserOverrideSet()
Enables users to check in content for other users.
This affects the Author option list on checkin pages. By default, only administrators are allowed to specify another user as the Author during checkin.
Type and Usage
Parameters
The only parameter is the value TRUE
or FALSE
.
Output
Evaluates to TRUE
if the user override is enabled.
Example
Enables users to check in content items with another user specified as the Author:
<$isUserOverrideSet(true)$>
See Also
A.226 isValidateFile()
Used as a parameter to the Upload
applet. This variable verifies that the file to be uploaded exists. In order to be used, a component must be created that overwrites the applet definition as defined in the std_multiupload_applet_definition
include in the std_page.htm
resource file.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Example
Used as a configuration entry:
isValidateFile=true
A.227 isVerboseTrace
Checks if a section is being traced in the core. Verbose trace generates a full report.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Output
-
Returns
TRUE
if tracing is set to Verbose. -
Returns
FALSE
if tracing is set to any other debug level.
Example
<$isVerboseTrace()$>
See Also
A.228 IsWindows
Checks if the client browser is running on a Windows operating system.
Type and Usage
Output
-
Returns
TRUE
if the client browser is running on Windows. -
Returns
FALSE
if the client browser is not running on Windows.
Example
Redirects to a different URL if the browser is running on Windows:
<$if IsWindows$> <a href="<$redirect$>"> <$endif$>
A.229 IsWorkflow
Checks if the content item on a checkin page is in a workflow.
Type and Usage
Output
-
Returns
TRUE
if the content item is in a workflow. -
Returns
FALSE
if the content item is not in the workflow.
A.230 IsXml
Displays a raw dump of the HTML form when set to TRUE
in a URL to a HCSP or HCSF file. This is useful for extracting form data or submitting forms from a remote application.
Type and Usage
Output
-
Returns the XML data contained in the form.
A.231 isZoneSearchField
This function is used to specify a field for full text searching.
Type and Usage
Parameters
The name of the field to be checked.
A.232 js()
Formats a string for use in a "..." JavaScript literal string declaration.
This function performs string manipulation such as changing double quotes to single quotes.
Type and Usage
Parameters
The only parameter is the string.
Output
Returns a string formatted for use in a JavaScript string declaration.
Example
Formats the string variablestring for use in a JavaScript string declaration:
<$js("variablestring")$>
A.233 jsFilename()
Used by the schema. Encodes a string that may contain non-ASCII characters into the valid filename strings required for the operating system and Java Script (performs an encoding function).
Type and Usage
Parameters
The only parameter is the string to be encoded.
Output
Returns an encoded string.
Example
<$jsFilename(fileName)$>
A.234 Json
Displays the local data of a Content Server web page.
This variable can be set as a flag on a page or as a parameter to a service call.
Type and Usage
Output
When set to TRUE
, returns the local data in the DataBinder in a JavaScript object, in compliance with the JSON (Javascript over network) specification.
Example
When included in the code on a Content Server web page, displays the local data of a page:
<$Json=1$>
When included in a Content Server URL, displays the local data for the New Checkin page:
http://myinstance.com/idcplg/idc_cgi_isapi-instance.dll?IdcService=CHECKIN_NEW_FORM&Json=1
A.235 lastEntryTs
Retrieves the timestamp from the last time the workflow step was entered.
This variable can be used to create conditional statements, but it should not be hard-coded or altered.
The last entry time is localized in the companion file and maintained in the key:
<step_name>@<workflow_name>.lastEntryTs
Type and Usage
Output
Returns the timestamp in the format defined by dateCurrent.
Example
The following code defines a jump called LastEntry
, which exits to the parent workflow and notifies the reviewers if the last time the step was entered was more than one week ago:
<$if parseDate(wfCurrentGet("lastEntryTs")) < parseDate(dateCurrent(-7))$> <$wfSet("WfJumpName","LastEntry")$> <$wfSet("WfJumpTargetStep",wfExit(0,0))$> <$wfSet("WfJumpEntryNotifyOff","0")$> <$endif$>
A.236 lc()
Retrieves the value of a localization string based on the current user's locale.
Type and Usage
Parameters
Takes one required parameter and any number of optional parameters:
-
The first parameter is the localization key (such as
apLabelHelp
orwwMyString
). -
The optional parameters are expressions that are resolved according to arguments inside curly braces in the localized string (for example,
{1}
).
Output
-
Returns the value of the localization string for the current user's locale.
-
Returns the string ID (such as wwMyString) if the value is not found.
Example
Retrieves the options for metadata search operators on a search page:
<select name="op" > <option value="Contains"><$lc("wwContains")$> <option value="Matches"><$lc("wwMatches")$> <option value="Starts"><$lc("wwStarts")$> <option value="Ends"><$lc("wwEnds")$> <option selected value="Substring"><$lc("wwSubstring")$> </select>
Sets the subject line for a workflow started notification email. If the name of the workflow (dWfName) is Marketing, the resulting value in English is Workflow 'Marketing' has been started.
<@dynamichtml wf_started_subject@> <$lc("wwWfStarted", dWfName)$> <@end@>
A.237 lcCaption()
Function that wraps a string into a caption. This will usually place a colon to the right of the string. For right-to-left reading languages, such as Hebrew and Arabic, the colon is placed on the left of the string.
Type and Usage
Parameters
Takes one required parameter:
-
The string to be wrapped.
-
optional parameters are expressions that are resolved according to arguments inside curly braces in the localized string (for example,
{1}
).
A.238 LmDefaultLayout()
Defines the default layout to use (for example, Trays
or Top Menus
).
The default installation value is Trays
.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
IntradocDir
/config/config.cfg
Example
LmDefaultLayout=Top Menus
A.239 LmDefaultSkin()
Defines the default skin to use (for example, Oracle, Oracle2).
Type and Usage
Location
IntradocDir
/config/config.cfg
Example
LmDefaultSkin=Oracle
A.240 lmGetLayout()
Retrieves the layout chosen by the user (for example, Trays
or Top Menus
).
Type and Usage
Parameters
None.
Example
<$lmGetLayout()$>
See Also
A.241 lmGetSkin()
Retrieves the skin selected by the user.
Type and Usage
Parameters
None.
Example
<$lmGetSkin()$>
See Also
A.242 loadCollectionInfo()
Loads metadata for a search collection.
Used by the search service to load metadata about a search collection.
This function is not intended for user configuration.
Type and Usage
Parameters
Takes one parameter, the name of the search collection to be loaded.
Output
None.
Example
Loads search collection information:
<$loadCollectionInfo(collection_name)$>
A.243 loadDocMetaDefinition()
Loads the DocMetaDefinition
database table into the active data as a ResultSet.
After the DocMetaDefinition
database table is loaded, it can be looped on.
Type and Usage
Parameters
None.
Output
None.
Example
Loads the DocMetaDefinition
table into the active data as a ResultSet.
<$loadDocMetaDefinition()$>
A.244 loadDocumentProfile()
Loads a content profile as specified by the trigger value for page presentation. This is called during the presentation of Search, Check In, Info, and Update pages. This function is called on request and the page on which it is called determines the action (for example, search, or info).
This information is dependent on context. The isCheckin
, isUpdate
, isQuery
, or isInfo
variables are set in local data and direct the loadDocumentProfile
function to the page to be loaded and presented.
Type and Usage
Parameters
None.
Output
None.
Example
<$loadDocumentProfile()$>
See Also
A.245 loadEnterpriseSearchCollections
This function loads the ResultSet EnterpriseSearchCollections
, used to display a list of remote Content Server instances that can be queried with Enterprise Search. This data is used on a Search page to allow the user to select which servers to query.
Type and Usage
Parameters
Takes one parameter. When set to zero, the ResultSet will not include the names of servers that are automatically searched.
A.246 loadEnterpriseSearchResults
This function renames certain ResultSets on the page to support Enterprise Search. It is used when looping over the ResultSet EnterpriseSearchResults
. It loads the ResultSet from the specific server and renames it to SearchResults
. This helps to simplify the IdocScript used on the Search Results page.
Type and Usage
Parameters
None
A.247 loadSchemaData()
Loads the data from a schema ResultSet into the local data of the current data binder.
Type and Usage
Parameters
This function can take zero, one, or two parameters.
-
If passed zero arguments, it fills the data binder with the data in the active ResultSet's row. Returns no value.
-
If passed one argument, the argument is the name of the ResultSet to get the values from the current row. Returns no value.
-
If passed two arguments, the first argument is the ResultSet name and the second argument is the key identifying the data object to load. Returns 0 if the data does not exist or 1 if it does exist. The use is True() or False() to conditionally execute scripts based on the return value.
Example
<$loadSchemaData()$>
See Also
A.248 loadSearchOperatorTables()
Loads mappings between the full set of operator names and the search syntax. Used on the Search page.
Type and Usage
Parameters
None.
Output
Returns expressions associated with operator names (search operator map).
Example
<$loadSearchOperatorTables()$>
A.249 loadUserMetaDefinition()
This function loads the custom user metadata definition. This exists in the UserMetaDefinition
table which is placed on the page as a ResultSet. This is used on LDAP administration pages to help administers map user metadata to the Content Server instance.
Type and Usage
Parameters
None.
A.250 LocalGroupServer
Specifies a Windows Server on which local groups are treated like global (domain) groups for NTLM security.
When the UseLocalGroups setting is TRUE, local groups on the Windows Server specified by this setting are mapped to roles and accounts as if they were global (domain) groups in the default master domain.
Default is the domain controller of the default master domain.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
Configure NT Domain Security page, Local Group Server
-
instance_dir/data/users/config/filter.hda
Example
Used as a configuration entry:
LocalGroupServer=server1
See Also
-
UseLocalGroups in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content.
A.251 localPageType
This function returns the page type for a page in the library folders. This may be a directory or a query page. This function is usually used by the Layout Manager API. When Trays
is the chosen layout, the function is used to construct a tree view of the library's pages.
Type and Usage
Parameters
Takes one parameter, the link data used to construct the tree view.
A.252 MajorRevSeq
Defines the major sequence for revision numbers.
Returns the major revision label sequence (returns the value of the configuration setting).
Returns a string.
Default is 1-99.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Options tab, Major Revision Label Sequence
-
Administration, Admin Server, General Configuration menu option, Major Revision Label Sequence
-
IntradocDir
/config/config.cfg
Example
As a configuration setting:
MajorRevSeq=A-Z
As script, returns the value of the configuration setting:
<$MajorRevSeq$>
See Also
A.253 MaxCollectionSize
Defines the number of files to be passed to the Indexer in one batch.
Valid range is 1 to 65535.
A value of 2000 is recommended for large index collections. Lower values will result in inefficient indexing performance.
Returns the number of files per batch.
Default is 25.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
Repository Manager, Indexer tab, Configure, Content Items Per Indexer Batch
-
IntradocDir
/config/config.cfg
Example
As a configuration setting, defines the batch size:
MaxCollectionSize=25
As script, returns the value from configuration files:
<$MaxCollectionSize$>
A.254 maxLength
Sets the maximum number of characters allowed in a metadata field.
Type and Usage
Output
Returns the maximum length of the field.
Example
Sets the maximum length of the field to 100 characters:
<$maxLength=100$>
Specifies a custom field length based on the length of the current field:
<$customFieldLength = getValue("#active", fieldName & ":maxLength")$>
A.255 MinorRevSeq
Defines the minor sequence for revision numbers.
Returns the minor revision label sequence (returns the value of the configuration setting).
Returns a string.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Options tab, Minor Revision Label Sequence
-
Administration, Admin Server, General Configuration menu option, Minor Revision Label Sequence
-
IntradocDir
/config/config.cfg
Example
As a configuration setting:
MinorRevSeq=a-c
As script, returns the value of the configuration setting:
<$MinorRevSeq$>
See Also
A.256 MSIE
Checks whether the client browser is Microsoft Internet Explorer.
Type and Usage
Output
-
Returns
TRUE
if the client browser is Internet Explorer. -
Returns
FALSE
if the client browser is not Internet Explorer.
Example
Redirects to a different URL if the browser is anything other than Internet Explorer:
<$if not MSIE$> <a href="<$redirect$>"> <$endif$>
A.257 MultiUpload
Enables the multiple-file Upload Applet.
When set to TRUE
, the Upload Applet is enabled so that multiple files can be zipped and checked in as a single content item.
When set to FALSE
, the Upload Applet is disabled. The default is FALSE
.
To see the Upload Applet on the Checkin page, select Enable upload applet
on the User Profile page, then click Update. Once the checkin begins, a progress bar shows in the applet.
DisableHttpUploadChunking
is set to true
by default in the config.cfg
file. To enable chunking, set DisableHttpUploadChunking=false.
However, if chunking is enabled, the requestaudit
tracing shows the following output for every chunk uploaded:
requestaudit 11.15 15:55:47.835 IdcServerThread-32 CHUNKED_UPLOAD dUser=sysadmin][IsJava=1] 8.361(secs)
To specify how big a file must be to trigger chunking, set AppletChunkThreshold
. This defaults to 1 MB
, and does not need to be set if 1 MB is sufficient.
AppletChunkThreshold=10000000
To specify the chunk size, set AppletChunkSize
, which also defaults to 1 MB
. This does not need to be set unless you want something other than 1 MB chunks.
AppletChunkSize=10000000
The CHUNKED_UPLOAD service is used for uploading from the Upload Applet with chunking enabled. This service takes each chunk of the upload and places it in the ucm/vault/~temp
directory. As chunks are uploaded, each chunk is appended to the main file. Once the upload completes, the file is moved to its proper location in the vault.
Chunking the upload for large files has the benefit of retrying the upload from the point of failure, if a network issue occurs during the upload (without having to start the entire upload over again.
A sample CHUNKED_UPLOAD POST request body is shown below:
Note:
Square quoted parts are descriptions, not parts of actual request. This request body is only for uploading one file.Figure A-1 Sample CHUNKED_UPLOAD POST request body
Description of "Figure A-1 Sample CHUNKED_UPLOAD POST request body"
To see chunkedrequest
tracing in the Content Server output, enable this setting in the config.cfg
file, and on the System Audit Information page, enable the tracing section chunkedrequest
.
ChunkedRequestTrace=true
The chunkedrequest
tracing output will look like the output in the following example. Note that TranedSize
means "transactioned size" or the total size uploaded so far:
chunkedrequest 11.15 15:55:47.780 IdcServerThread-32 In doUpload() chunkedrequest 11.15 15:55:47.780 IdcServerThread-32 TranedSize: 15000000 chunkedrequest 11.15 15:55:47.780 IdcServerThread-32 Retrieve Session: 983887704 chunkedrequest 11.15 15:55:47.831 IdcServerThread-32 Leaving doUpload() chunkedrequest 11.15 15:55:47.831 IdcServerThread-32 Register new entry in ChunkSessionManager. chunkedrequest 11.15 15:55:47.831 IdcServerThread-32 SessionID: 983887704TimeOut: 213222ms. chunkedrequest 11.15 15:55:47.831 IdcServerThread-32 Session 983887704 is inserted in timeout queue at index 0 requestaudit 11.15 15:55:47.835 IdcServerThread-32 CHUNKED_UPLOAD [dUser=sysadmin][IsJava=1] 8.361(secs)
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Location
-
System Properties, Options tab, Enable upload applet
-
Administration, Admin Server, General Configuration menu option, Enable upload applet
-
IntradocDir
/config/config.cfg
Example
As a configuration setting, enables the Upload Applet:
MultiUpload=true
As script, evaluates the condition of the Upload Applet:
<$MultiUpload$>
See Also
A.258 NoMatches
Checks whether matches were found from a search query.
Generally used to display a message on the search results page.
Type and Usage
Output
-
Returns
TRUE
if no matches were found. -
Returns
FALSE
if any matches were found.
Example
Displays text if no matches were found from a query:
<$if NoMatches$> <p><font face="arial" size="2"> Found no matches out of <$TotalDocsProcessed$> documents searched matching the query.</p> <$endif$>
A.259 noMCPrefill
Specifies that the MultiCheckin component should not prefill metadata fields.
This variable can be used on special pages such as custom HCST and Contribution Folders component pages.
When set to TRUE
, the MultiCheckin component will not prefill metadata fields.
When set to FALSE
, the MultiCheckin component will prefill metadata fields.
Type and Usage
Output
-
Returns
TRUE
if the MultiCheckin component will not prefill metadata fields. -
Returns
FALSE
if the MultiCheckin component will prefill metadata fields.
Example
Set near the top of the page:
noMCPrefill=1
Used as script:
<$noMCPrefill$>
A.260 NotificationQuery
This setting defines criteria for the automatic query that searches for expired content.
If NotificationQuery
is not set, the default value is all content that expires in the next seven days.
Type and Usage
-
Configuration Variables in Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
Parameters
There is one parameter, the query to be used. The query can be one of the following. For sample queries, see the following Example section.
-
An Idoc Script query, built from Idoc Script.
-
A URL encoded query. This uses the URL displayed in the web browser address when a search is performed.
-
A plain text query which defines the search variables.
Location
IntradocDir
/config/config.cfg
Example
Idoc Script Example
When used in conjunction with database indexing, the following query provides email notification for all documents that expire in seven days:
NotificationQuery=dOutDate < '<$dateCurrent(7)$>'>
URL Encoded Example
The following query returns all content expiring after August 1, 2007. The URL from the browser address line is copied, beginning with the QueryText
portion:
NotificationQuery=QueryText=dOutDate+%3C+%608%2F1%2F06%60&SearchProviders= [...}
Plain Text Query
The following query returns all content expiring after August 1, 2007:
NotificationQuery=8/1/07
See Also
-
"EnableExpirationNotifier" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
-
"NotificationIntervalInDays" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
-
"NotificationMaximum" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
-
"NotifyExtras" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
-
"NotifyTime" in the Oracle Fusion Middleware Configuration Reference for Oracle WebCenter Content
A.261 OneMatch
Checks if only one match was found from a search query.
Generally used to display a message on the search results page.
Type and Usage
Output
-
Returns
TRUE
if only one match was found. -
Returns
FALSE
if no matches or more than one match were found.
Example
Displays text if only one match was found from a query:
<$if OneMatch$> <p><font face="arial" size="2"> Found <$TotalRows$> document matching the query.</p> <$endif$>
A.262 optionListKey
Specifies the name of a ResultSet
column that contains option list values.
Type and Usage
Output
Returns the values of the option list ResultSet
column.
Example
Specifies dFormat
as the column in the DocFormats
ResultSet to get option list values from for the standard Format
field on a checkin page:
<@dynamichtml std_override_format_field@> <$if not isInfo and IsOverrideFormat$> <$fieldIsOptionList = 1, optionListResultSet = "DocFormats", optionListKey = "dFormat", optionListValueInclude = "std_override_format_option_value", addEmptyOption = 1, emptyOptionLabel = lc("wwEmptyFormatOption")$> <$include std_display_field$> <$endif$> <@end@>7
See Also
A.263 optionListName
Specifies the name of an option list.
For standard metadata fields, this is the name of the internal option list. For more information, see Internal Option Lists.
For custom metadata fields, this is the name of the field with a suffix of .options
.
Type and Usage
Output
Returns the option list name.
Example
Sets the option list name to docAuthors
if the field is not restricted to a single user:
<$if SingleUser$> <$isInfoOnly = 1$> <$else$> <$fieldIsOptionList = 1, optionListName = "docAuthors"$> <$if HasExternalUsers$><$fieldOptionListType= "combo"$> <$endif$> <$endif$>
Defines the default option list script:
<$if optionsAllowPreselect and fieldValue$> <$defaultOptionListScript = "<$optList " & optionListName & ":fieldValue$>"$> <$else$> <$defaultOptionListScript = "<$optList " & optionListName & ":noselected$>"$> <$endif$>
A.264 optionListResultSet
Specifies the name of a ResultSet that contains option list values.
Type and Usage
Output
Returns the option list ResultSet.
Example
Specifies DocFormats as the option list ResultSet for the standard Format field on a search page:
<@dynamichtml std_format_fields@> <$if ClientControlled or dFormat or dExtension$> <$fieldName = "dFormat", fieldCaption = lc("wwNativeFormat"), optionListResultSet = "DocFormats"$> <$include std_display_field$> <$fieldName = "dExtension", fieldCaption = lc("wwNativeExtension"), fieldWidth = 10$> <$include std_display_field$> <$endif$> <@end@>
Creates an option list by looping over a ResultSet:
<@dynamichtml compute_resultset_option_list_script@> <$if not optionListKey$> <$optionListKey = fieldName$> <$endif$> <$defaultOptionListScript = "<$loop " & optionListResultSet & "$>" & "<$inc('std_resultset_option_list_item')$>" & "<$endloop$>"$> <@end@>
A.265 optionListScript
When this variable is set to a non-empty value, the eval function is used when displaying the option list for the field. This variable allows the standard implementation of option lists (defined by the defaultOptionListScript
variable) to be overridden.
Type and Usage
Output
-
Returns
TRUE
if the value is nonempty. -
Returns
FALSE
if the value is an empty string.
Example
Defines a custom script for creation of an option list:
<$customOptionListScript = getValue("#active", fieldName & ":optionListScript")$>
See Also
A.266 optionListValueInclude
Specifies an include that defines the values for an option list.
Type and Usage
Output
Returns the include code.
Example
Defines std_override_format_option_value
as the option list value include:
<@dynamichtml std_override_format_field@> <$if not isInfo and IsOverrideFormat$> <$fieldIsOptionList = 1, optionListResultSet = "DocFormats", optionListKey = "dFormat", optionListValueInclude = "std_override_format_option_value", addEmptyOption = 1, emptyOptionLabel = lc("wwEmptyFormatOption")$> <$include std_display_field$> <$endif$> <@end@> <@dynamichtml std_override_format_option_value@> <$dDescription$> <@end@>
Specifies the include to use to display options in an option list from a ResultSet:
<@dynamichtml std_resultset_option_list_item@> <$curValue = getValue("#active", optionListKey)$> <option value="<$curValue$>" <$if optionsAllowPreselect and strEquals(curValue, fieldValue)$>selected<$endif$>> <$if optionListValueInclude$> <$inc(optionListValueInclude)$> <$else$> <$curValue$> <$endif$> <@end@>
See Also
A.267 optionsAllowPreselect
Specifies that the metadata field option list can be prefilled with its last value.
Type and Usage
Output
-
Returns
TRUE
if the option list can be prefilled. -
Returns
FALSE
if the option list cannot be prefilled.
Example
Specifies that the option list can be prefilled:
<$optionsAllowPreselect=1$>
Determines if the option list will be prefilled:
<$if optionsAllowPreselect and fieldValue$> <$defaultOptionListScript = "<$optList " & optionListName & ":fieldValue$>"$> <$else$> <$defaultOptionListScript = "<$optList " & optionListName & ":noselected$>"$> <$endif$>
A.268 optList()
Generates an option list.
This function is used extensively to create option lists on Content Server pages.
This function only produces output when used with a service that calls loadMetaOptionsList
Type and Usage
Parameters
Takes one parameter and one optional argument to the parameter:
The only parameter is a field name, option list key, or variable.
-
Field name syntax is
<$optList fieldName$>
. For custom metadata fields, the field name will resolve to<$optList xFieldName.options$>
, or you can specify the.options
suffix directly. -
Option list key syntax is
<$optList ListName$>
.-
For standard metadata fields, the
ListName
value is the name of the internal option list (such asdocAuthors
). For more information, see Internal Option Lists. -
For custom metadata fields, the
ListName
is the name of the option list key, such asFieldNameList
.
-
-
Variable syntax is
<$optList variable$>
. The variable must resolve to a field name or an option list key. -
One of the following optional arguments can be added to the parameter:
-
:noselected-No values are selected when the option list is displayed.
-
:fieldValue-The value specified by the fieldValue variable is selected as the default value in the option list.
-
Output
Returns a list of values.
Example
This script generates a list of possible authors from the internal docAuthors list:
<$optList docAuthors$>
This script generates a list of the options specified in the xRegion custom metadata field:
<$optList xRegion.options$>
This script generates an option list from the variable optionListName and specifies the default value:
<$if optionsAllowPreselect and fieldValue$> <$defaultOptionListScript = "<$optList " & optionListName & ":fieldValue$>"$> <$else$> <$defaultOptionListScript = "<$optList " & optionListName & ":noselected$>"$> <$endif$>
A.269 PageParent
Checks whether a directory page in the Library has a parent page.
Type and Usage
Output
-
Returns
TRUE
if the directory page is a child (subfolder) of another directory page. -
Returns
FALSE
if the directory page is not a child (subfolder).
Example
Checks if the directory page is a subfolder:
<$PageParent$>
A.270 parseDataEntryDate()
Parses a date but uses the failover logic for using the alternate parsing formats.
Dates convert to milliseconds when used with standard comparison operators. For example, the expression (60*60*1000)
equals one hour.
A common usage of this function is to adjust the current time using a multiplication expression that represents a number of seconds, minutes, hours, or days.
Type and Usage
Parameters
The only parameter is an expression to be parsed.
Output
Returns a Java date object, which is converted to a string for display.
Example
<$parseDataEntryDate$>
A.271 parseDate
Parses a date/time to allow evaluation and arithmetic.
Dates convert to milliseconds when used with standard comparison operators. For example, the expression (60*60*1000)
equals one hour.
A common usage of this function is to adjust the current time using a multiplication expression that represents a number of seconds, minutes, hours, or days.
Type and Usage
Parameters
The only parameter is an expression to be parsed.
Output
Returns a Java date object, which is converted to a string for display.
Example
Each of the following expressions returns the date and time one day in the past:
<$parseDate(dateCurrent(-1))$> <$parseDate(dateCurrent()-(24*60*60*1000))$> <$dateCurrent(-1)$> <$dateCurrent()-(24*60*60*1000)$>
Returns the time one hour in the future. The first line adds one hour using a time multiplication expression, assigns that time and date to a custom variable, and suppresses the output. The second line references the custom variable and defines that only the time is displayed:
<$exec my_customParseTime parseDate(dateCurrent()+(1000*60*60))$> <$formatTimeOnly(my_customParseTime)$>
Returns the date one year in the future. The first line adds one year using a time multiplication expression, assigns that time and date to a custom variable, and suppresses the output. The second line references the custom variable and defines that only the date in long format is displayed:
<$exec my_customParseTime parseDate(dateCurrent()+(1000*60*60*24*365))$> <$formatTimeOnly(my_customParseTime)$>
This script evaluates whether the date seven days in the future is greater than the expiration date and returns a message to the user if true:
<$if dOutDate$> <$if dateCurrent(7) > parseDate(dOutDate)$> Content item expires in one week. <$endif$> <$endif$>
This script uses parseDate
within a conditional statement for customized workflow jumps. The script specifies that if the last time we entered this step was four days ago, go to the first step in workflow wf_late
and set the return step to be the next step:
<$if parseDate(wfCurrentGet("lastEntryTs")) < dateCurrent(‐4)$> <$wfSet("wfJumpName", "lateJump")$> <$wfSet("wfJumpTargetStep", "step_1@wf_late")$> <$wfSet("wfJumpReturnStep", wfCurrentStep(1))$> <$wfSet("wfJumpEntryNotifyOff", "0")$> <$endif$>
See Also
A.272 parseDateWithPattern()
Parses a date/time to a specified date/time pattern.
Dates convert to milliseconds when used with standard comparison operators. For example, the expression (60*60*1000)
equals one hour.
A common usage of this function is to adjust the current time using a multiplication expression that represents a number of seconds, minutes, hours, or days.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is a date string used by the Content Server instance, or a date object created with the parseDate or dateCurrent function.
-
The second parameter is the date/time pattern, which is a standard Java
SimpleDateFormat
pattern string, such asMM/dd/yyyy
.
Output
Returns a Java date object, which is converted to a string for display.
Example
Displays the current date and time in the format specified by the pattern (for example, Wed, 4 Jul 2001 12:08:56 -0700
):
<$parseDateWithPattern(dateCurrent(),"EEE, d MMM yyyy HH:mm:ss Z")$>
A.273 PATH_INFO
This setting is obsolete. The web server filter no longer sends this information.
Retrieves additional information about the file system path to the CGI computer.
When the virtual path is returned by the PATH_TRANSLATED variable, any additional information at the end of this path is also returned as PATH_INFO.
This variable is specific to the current gateway program request.
Type and Usage
Output
Returns the additional virtual path information as a string.
Example
Retrieves additional CGI path information:
<$PATH_INFO$>
See Also
A.274 PATH_TRANSLATED
Retrieves the file system path to the CGI computer, for example:
c:/domain/weblayout/idcplg/idc_cgi_isapi-idcm1.dll.
This variable is specific to the current gateway program request.
Type and Usage
Output
Returns the virtual path as a string.
Example
Retrieves the CGI path:
<$PATH_TRANSLATED$>
A.275 pneNavigation()
Enables the left sidebar navigation.
Type and Usage
Parameters
Set as a name/value pair:
pneNavigation=1
Default value is 1 (enabled).
To disable this function, it must be set to a null string.
Output
Evaluates to TRUE
or FALSE
.
Example
Enables the sidebar navigation:
<$pneNavigation=1$>
To force the sidebar navigation off, set it to a null string:
<$pneNavigation=""$>
Setting the definition to other than 1 or a null string value is invalid and will not disable the sidebar navigation:
<$pneNavigation=0$>
A.276 proxiedBrowserFullCgiWebUrl
Returns the complete CGI path of a proxied Content Server instance.
Type and Usage
Parameters
The only parameter is the relative web root of the proxied Content Server instance. This value is found in the HttpRelativeWebRoot
setting.
Output
Returns the complete CGI path of the specified proxy as a string.
Example
Returns http://<localhost/idcplg/idc_cgi_isapi-idcm1.dll/intradoc4/pxs:
<$proxiedBrowserFullCgiWebUrl("/intradoc4/")$>
See Also
A.277 proxiedCgiWebUrl
Returns the CGI path of a proxied Content Server instance.
Type and Usage
Parameters
The only parameter is the relative w root of the proxied Content Server instance. This value is found in the HttpRelativeWebRoot
setting.
Output
Returns the CGI path of the specified proxy as a string.
Example
Returns /idcplg/idc_cgi_isapi-idcm1.dll/intradoc4/pxs:
<$proxiedCgiWebUrl("/intradoc4/")$>
See Also
A.278 QUERY_STRING
Retrieves the string that follows the ? delimiter in the URL for a query.
This variable is specific to the current CGI request.
Type and Usage
Output
Returns the query information as a string.
Example
As information output on a page or to a log:
QUERY_STRING=IdcService=GET_DOC_PAGE&Action=GetTemplatePage&Page=STD_QUERY_PAGE
As part of an Idoc Script statement or evaluation:
<$if QUERY_STRING$>
<!--statement-->
A.279 regexMatches()
Searches a string for a specific pattern using a regular expression to do matching. Regular expression constructs can contain characters, character classes, and other classes and quantifiers. For details about the Java API for Class Pattern, see http://www.oracle.com/technetwork/java/index.html
.
This feature is only available with JVM 1.4 or later versions; this is the default version for WebCenter Content version 7.0 and later.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is the string to match.
-
The second parameter is the expression.
Example
The following example returns FALSE
, because the string does not match the expression:
<$regexMatches("abcdef","abc")$>
The following example returns TRUE
because the wild cards are present. If standard wild cards such as the asterisk (*) were used instead of the dot-asterisk (.*) convention, the match would fail.
<$regexMatches("abcdef", ".*abc.*")$>
A.280 regexReplaceAll()
Searches a string for a specific pattern using a regular expression to do matching and replacing. Regular expression constructs can contain characters, character classes, and other classes and quantifiers. For details about the Java API for Class Pattern, see http://www.oracle.com/technetwork/java/index.html
.
This feature is available only with JVM 1.4 or later versions; this is the default version for WebCenter Content version 11.1.1.7.0 and later.
It replaces all instances of the regular expression with the replacement string.
Type and Usage
Parameters
Takes three parameters:
-
The first parameter is the original string.
-
The second parameter is the string to match.
-
The third parameter is the replacement string.
Example
The following example returns xyzdef xyzdef
:
<$regexReplaceAll("abcdef abcdef","abc","xyz")$>
A.281 regexReplaceFirst()
Searches a string for a specific pattern using a regular expression to do matching and replaces the first instance with a replacement string. Regular expression constructs can contain characters, character classes, and other classes and quantifiers. For details about the Java API for Class Pattern, see http://www.oracle.com/technetwork/java/index.html
.
This feature is only available only with JVM 1.4 or later versions; this is the default version for WebCenter Content version 11.1.1.7.0 and later.
Type and Usage
Parameters
Takes three parameters:
-
The first parameter is the original string.
-
The second parameter is the string to match.
-
The third parameter is the replacement string.
Example
The following example returns xyzdef abcdef
:
<$regexReplaceFirst("abcdef abcdef","abc","xyz")$>
A.282 REMOTE_ADDR
Returns the IP address of the remote host making the request.
This variable is specific to the current gateway program request.
Type and Usage
Output
Returns the IP address as a string.
Example
As information output on a page or to a log:
REMOTE_ADDR=207.0.0.1
As part of an Idoc Script statement or evaluation:
<$if REMOTE_ADDR$>
<!--statement-->
See Also
A.283 REMOTE_HOST
Returns the name of the remote host making the request.
This variable is specific to the current gateway program request.
Type and Usage
Output
-
Returns the host name as a string.
-
If the hostname is unknown to the server, returns the value of REMOTE_ADDR as a string.
Example
As information output on a page or to a log:
REMOTE_HOST=207.0.0.1
As part of an Idoc Script statement or evaluation:
<$if REMOTE_HOST$>
<!--statement-->
See Also
A.284 REQUEST_METHOD
Retrieves the method that was used to make the request.
This variable is specific to the current gateway program request.
Type and Usage
Output
Returns the request method as a string.
Example
As information output on a page or to a log:
REQUEST_METHOD=GET
As part of an Idoc Script statement or evaluation:
<$if REQUEST_METHOD$>
<!--statement-->
A.285 requiredMsg
Specifies the error message to be displayed if a required metadata field does not have a value upon checkin.
Type and Usage
Output
Returns the error message as a string.
Example
Defines the required field error message for the dDocTitle metadata field as the wwSpecifyTitle
localized string:
<$fieldName = "dDocTitle", fieldCaption = lc("wwTitle"), isRequired = 1, fieldType = "BigText", requiredMsg = lc("wwSpecifyTitle")$>
See Also
A.286 ResultsTitle
Defines a title for the search results page.
This variable is used by the Web Layout Editor to name the search results page and display a heading at the top of that page.
Usage
Output
Returns the page title as a string.
Example
As an HDA entry, names the search results page:
@Properties LocalData ResultsTitle=Content Items @end
As a script, returns the defined name:
<$if ResultsTitle$>ResultsTitle=<$url(ResultsTitle)$>
A.287 rptDisplayMapValue()
This function is meant for internal use only.
This function returns a localized string representation of an internal key code. These key codes are used to store status and state flags for content items. This function is used on the Content Information page and workflow pages to display descriptions of the internal state.
Type and Usage
Parameters
Takes two parameters:
-
The name of the table where the keys are stored.
-
The key to be localized.
A.288 rs()
This function returns a ResultSet given the name of the ResultSet. Because the actual object it returns is a ResultSet, certain actions can be performed on the return value that cannot be performed on the return values of other functions. In particular, the loop syntax can be applied to the result.
Type and Usage
Parameters
This function has one parameter, resultSetName
, which is the name of the ResultSet to return.
Output
A ResultSet object if found, otherwise null.
Example
Suppose MyResultSet
is the name of a ResultSet, then you could loop on the ResultSet using the following syntax:
<$loop rs("MyResultSet")$>... Script inside loop ...<$endloop$>
This function also can be used when temporarily assigning variables when calling Idoc Script functions. In particular, the following example will temporarily assign the variable rsParam
to point to the same ResultSet as pointed to by MyResultSet
for the duration of the call to include the resource include my_include
. If the result of the rs
function is assigned to a variable, then that variable will have a shared pointer to the ResultSet creating the same effect as if rsCreateReference
were called.
<$inc("my_include", rsParam=rs("MyResultSet"))$>
A.289 rsAddFields()
Adds new fields to a ResultSet. This function will only add the field if it is not already present. Note that setValue(...) can also add new fields but it only works on ResultSets that are nonempty and are on a currently valid row.
Type and Usage
Parameters
Takes two parameters:
-
The first parameter is the name of the ResultSet to get new fields (columns) added.
-
The second parameter is a comma separated list of fields to add.(the column names to be added).
Output
-
Returns
TRUE
if the function is successful. -
Returns
FALSE
if the function fails.
Example
<$rsAddFields(rsName, fieldsList)$>
A.290 rsAddFieldsWithDefaults()
This function adds new fields to an existing ResultSet. Unlike rsAddFields
, this function provides the ability to specify default values for any fields that are added. Note that rsAddFieldsWithDefaults
never over-writes any data in fields that already exist; it only adds new fields to a ResultSet.
Type and Usage
Parameters
The following table lists parameters for the function.
Parameters | Description |
---|---|
|
The name of the ResultSet. |
|
A comma-separated list of fields to append to the ResultSet. Any specified fields that already exist in the ResultSet are ignored. |
|
An optional comma-separated list of default values that are set for the new fields in each row. Each value in this list corresponds to the new field in the same spot of the list newFields. If you need to set a default value with a comma in it, you can use '^' as a comma. If the defaultValues list is longer or shorter than newFields list, then the function ignores the extra default values or uses the empty string for unspecified default values, respectively. |
Output
Nothing.
Example
Adding fields
<$rsCreateResultSet("MyList", "field1,field2,field3")$><$rsAppendRowValues("MyList", "A,B,C,D,E,F")$><$rsAddFieldsWithDefaults("MyList", "field4,field5,field6")$>
In this basic example, we create a ResultSet named MyList
, fill it with some values, then add three more fields to MyList
, without setting default values. The resulting table will look like the following:
field1 | field2 | field3 | field4 | field5 | field6 |
---|---|---|---|---|---|
A |
B |
C |
|||
D |
E |
F |
Adding fields with default
<$rsCreateResultSet("MyList", "field1,field2,field3")$><$rsAppendRowValues("MyList", "A,B,C,D,E,F")$><$rsAddFieldsWithDefaults("MyList", "field4,field5,field6", "X,Y,Z")$>
Here we define default values for the new fields. The resulting table will look like the following:
field1 | field2 | field3 | field4 | field5 | field6 |
---|---|---|---|---|---|
A |
B |
C |
X |
Y |
Z |
D |
E |
F |
X |
Y |
Z |
When a field already exists
<$rsCreateResultSet("MyList", "field1,field2,field3")$><$rsAppendRowValues("MyList", "A,B,C,D,E,F")$><$rsAddFieldsWithDefaults("MyList", "field1,field4,field5", "X,Y,Z")$>
In this case, we try and add a field that already exists in MyList
. This action is completely ignored, and old field values are preserved. The resulting table will look like the following:
field1 | field2 | field3 |
---|