3 Master List: Idoc Script by Type

This chapter describes the different types of Idoc Script variables and functions, and groups the variables and functions by type.

3.1 Conditional Dynamic Variables

Some dynamic variables are conditional and can only be used within a conditional statement such as if, while, elseif, or loop. These variables have the following special features:

  • Conditional variables are internal flags that are gettable but not settable.

  • Conditional variables will only provide a Boolean response and do not return a value such as a string or integer.

  • Conditional variables will not accept the #active keyword prefix. Thus, an error report is printed to the debug output if the variable is not found.

The following is a list of Idoc Script conditional dynamic variables.


"AdminAtLeastOneGroup"
"AfterLogin"
"AllowCheckin"
"AllowCheckout"
"AllowReview"
"dcShowExportLink"
"EmptyAccountCheckinAllowed"
"HasPredefinedAccounts"
"HasUrl"
"HeavyClient"
"IsCheckinPreAuthed"
"isComponentEnabled"
"IsContributor"
"IsCriteriaSubscription"
"IsCurrentNav"
"IsDynamic"
"IsExternalUser"
"IsFilePresent"
"IsFullTextIndexed"
"IsLocalSearchCollectionID"
"IsLoggedIn"
"IsMac"
"IsMaxRows"
"IsMultiPage"
"IsNotSyncRev"
"IsPromptingForLogin"
"IsRequestError"
"IsSubAdmin"
"IsSun"
"IsSysManager"
"IsUploadSockets"
"IsUserEmailPresent"
"IsWindows"
"IsWorkflow"
"SingleGroup"
"UserIsAdmin"
"UserLanguageID"
"UserLocaleId"
"UseXmlUrl"

3.2 Configuration Variables

Configuration variables are predefined Idoc Script variables that are generally used as settings in configuration files. These variables can be used within Idoc Script to detect whether a configuration setting is enabled or to return the value of the configuration setting.

  • Configuration variables that pass a Boolean value can be set only to the value TRUE (1) or FALSE (0).

  • Unless otherwise specified, Boolean-type configuration values default to FALSE (0), and string-type configuration values default to an empty string.

This section lists the configuration variables by the configuration file (typically .cfg or .hda) in which they are most commonly located. Your actual application will vary depending on the criteria and selections made during installation.

3.2.1 Oracle Content Server Configuration Variables

The following configuration files are located in these configuration directories.

3.2.1.1 DomainHome/ucm/cs/bin/intradoc.cfg

The following configuration variables are located in the DomainHome/ucm/cs/bin/intradoc.cfg file. These variables define directory paths and global settings for the Oracle Content Server system and Admin Server.


"AllowConcurrentUpdate"
"ARCHIVE_COLLECTION"
"BatchLoaderPath"
"BatchLoaderUserName"
"CleanUp"
"CollectionLocation"
"DataDir"
"EnableErrorFile"
"FileEncoding"
"HTMLEditorPath"
"IdcAnalyzeLogDir"
"IdcCommandFile"
"IdcCommandLog"
"IdcCommandUser"
"IdcNativeDir"
"IntradocDir"
"isPhysicallySplitDir"
"JvmCommandLine"
"LogMessagePrefix"
"MaxErrorsAllowed"
"PreviewOutputExtension"
"PreviewPath"
"VaultDir"
"WebBrowserPath"
"WeblayoutDir"

3.2.1.2 IntradocDir/config/config.cfg

The following configuration variables are located in the IntradocDir/config/config.cfg file. These variables define instance settings for the Admin Server and most of the configuration settings for the Oracle Content Server system.


"AccessListPrivilegesGrantedWhenEmpty"
"AdditionalIndexBuildParams"
"AdditionalSubscriptionCollatedFieldList"
"AllowAllRedirectUrls"
"AllowAlternateMetaFile"
"AllowMatchesInDateCheck"
"AllowPrimaryMetaFile"
"AllowSamePrimaryAlternateExtensions"
"AppletChunkSize"
"AppletChunkThreshold"
"ARCHIVE_COLLECTION"
"ArchiverDoLocks"
"ArchiverTouchMonitorInterval"
"ArchiverTraceLockMaintenance"
"ArchiverTraceLocks"
"AuthorDelete"
"AutoNumberPrefix"
"AutoNumberWidth"
"BinDir"
"CachedResultRowCount"
"ChunkedRequestTrace"
"CollectionLocation"
"ColumnMapFile"
"ConfigDir"
"ConversionCacheExpirationPeriodInDays"
"CookieAuthTimeoutInDays"
"CookieProxyPassword"
"createAlternateMetaFile"
"createPrimaryMetaFile"
"DatabasePreserveCase"
"DatabaseWildcards"
"DatedCacheIntervalDays"
"DateOutputFormat"
"DCMaxFileSize"
"DCTimeOut"
"DCViewFormat"
"Default Accounts"
"DefaultFilterInputFormat"
"DefaultFilterOutputFormat"
"DefaultHtmlConversion"
"DefaultHtmlRefreshTimeoutInSeconds"
"DefaultPasswordEncoding"
"DirectoryLockingLogPath"
"DisableContentProfiles"
"DisableDBLongIntegerField"
"DisableForcedConversions"
"DisableHttpUploadChunking"
"DisableKeepingForcedConversions"
"DisableOptimizedLatestReleaseQuerying"
"DisableSharedCacheChecking"
"DoDocNameOrder"
"DomainControllerName"
"DownloadApplet"
"DtmPort"
"EnableDocumentHighlight"
"EnableEnvironmentPackager"
"EnableExpirationNotifier"
"EnableRebuildForcesReconversion"
"EnableSchemaPublish"
"ExclusiveCheckout"
"ExpireRevisionOnly"
"ForcedConversionRules"
"ForceDistinctRevLabels"
"ForceDocTypeChoice"
"ForceJdbcSync"
"ForceSecurityGroupChoice"
"FormInheritMetaDataFieldList"
"GetCopyAccess"
"HasExternalUsers"
"HighlightBegin"
"HtmlDataInputFilterLevel"
"HighlightEnd"
"HTMLEditorPath"
"HttpRelativeWebRoot"
"HttpServerAddress"
"IdcAuthExtraRequestParams"
"IdcCommandServerHost"
"IdcHttpHeaderVariables"
"IdcHomeDir"
"IdcLocale"
"IDC_Name"
"IdcServerBindAddress"
"IdcServerSocketQueueDepth"
"IndexableRenditions"
"IndexerAutoWorkInterval"
"IndexerLargeFileSize"
"IndexerRebuildStagingManualCopy"
"IndexerRebuildStagingPath"
"IndexerTouchMonitorInterval"
"IndexerTraceCycleListChanges"
"IndexerTraceLockFileChanges"
"IndexerTraceStartStop"
"InstanceDescription"
"InstanceMenuLabel"
"IntradocRealm"
"IntradocServerHostName"
"IntradocServerPort"
"IsAllowIndexRenditions"
"IsAutoArchiver"
"IsAutoNumber"
"IsAutoQueue"
"IsAutoSearch"
"IsContentRefineryPresent"
"IsDpSubmitErrorFatal"
"IsWebServerPagesOnly"
"IsDynamicConverterEnabled"
"IsFormsPresent"
"rule:IsFragmentOnly"
"IsJdbcLockTrace"
"IsJdbcQueryTrace"
"IsJspServerEnabled"
"IsOverrideFormat"
"IsSavedWfCompanionFile"
"JdbcConnectionString"
"JdbcDriver"
"JdbcPassword"
"JdbcPasswordEncoding"
"JdbcUser"
"JspAdminQuery"
"JspDefaultIndexPage"
"JspEnabledGroups"
"LatestReleasedTimestampTimeout"
"LmDefaultLayout"
"LmDefaultSkin"
"LocaleArchiverDateFormat"
"LogName"
"MacSupportsSignedApplets"
"MailServer"
"MajorRevSeq"
"MaxArchiveErrorsAllowed"
"MaxCollectionSize"
"MaxConversionCacheSizeInMegs"
"MaxDocIndexErrors"
"MaxIntegerAllowed"
"MaxQueryRows"
"MaxRequestThreadCount"
"MaxResults"
"MaxSavedSearchResults"
"MaxSearchConnections"
"MaxSizeResourceFileCacheMillions"
"MemoFieldSize"
"MinIntegerAllowed"
"MinMemoFieldSize"
"MinorRevSeq"
"MultiUpload"
"NeverTimeoutForcedConversionsTemplateChange"
"NoAutomation"
"noInfoColumn"
"noRevisionsColumn"
"NoSearchConnectionCloseOnDocChange"
"NotificationIntervalInDays"
"NotificationMaximum"
"NotificationQuery"
"NotifyExtras"
"NotifyTime"
"NtlmSecurityEnabled"
"NumAdditionalRenditions"
"NumConnections"
"OdbcDateFormat"
"PrimaryWorkQueueTimeout"
"ProviderDir"
"QueueDir"
"RedirectHostsFilter"
"RequestAuditAdditionalVerboseFieldsList"
"RequestAuditIntervalSeconds1"
"RequestAuditIntervalSeconds2"
"RequestAuditListDepth1"
"RequestAuditListDepth2"
"RequestAuditSubClassificationField"
"SchemaAllowRecursiveFileMove"
"SchemaBuildDigestFile"
"SchemaPublishCheckInterval"
"SchemaPublishInterval"
"SchemaPublishMaximumInterval"
"SchemaPublishMinimumInterval"
"SchemaPublishRenameRetryInitialInterval"
"SchemaPublishRetryInterval"
"SchemaPublishRetryIntervalMax"
"SchemaPublishRenameRetryIterations"
"SchemaVerifyPublishing"
"SchemaWin32RenameDelayInterval"
"SearchCacheCleanerInterval"
"SearchCacheHardLimit"
"SearchCacheMaxItemAgeInMinutes"
"SearchCacheSoftLimit"
"SearchCacheTrace"
"SearchConnectionWaitTimeout"
"SearchDebugLevel"
"SearchDir"
"SearchIndexerEngineName"
"SearchQueryFormat"
"SearchQueryTrace"
"SelfRegisteredAccounts"
"SelfRegisteredRoles"
"ServiceStartupTimeout"
"ShowCreateExternalMenu"
"showDocActions"
"ShowOnlyKnownAccounts"
"ShowRevisionsColumn"
"showSearchResultsCheckoutColumn"
"SkipMozillaMailToWorkaround"
"SmtpPort"
"SocketHostAddressSecurityFilter"
"SocketHostNameSecurityFilter"
"StdPageWidth"
"StrConfineOverflowChars"
"SubjectsDir"
"SubscriptionMethod"
"SubscriptionCollatedFieldList"
"SysAdminAddress"
"SystemDateFormat"
"SystemLocale"
"SystemTimeZone"
"TempDir"
"TimeoutChangedTemplateForcedConversionsInMins"
"TimeoutMismatchedForcedConversionsInMins"
"TimeoutPerOneMegInSec"
"TraceConversionCacheCleanup"
"TraceResourceConflict"
"TraceResourceLoad"
"TraceResourceOverride"
"UniversalSearchAllowFullText"
"UploadApplet"
"UseAccounts"
"UseAdsi"
"UseBellevueLook"
"UseCascadingStyleSheets"
"UseFourDigitYear"
"UseNtlm"
"UserCache"
"UserCacheTimeout"
"UseRedirectedOutput"
"UseRevisionCreateDate"
"UserFilteredSubjects"
"UserPublishCacheDir"
"UseSearchCache"
"UseSSL"
"UseXpedioLook"
"WarnAboutTimeZone"
"WebServerAuthOnly"
"WorkflowDir"
"WorkflowIntervalHours"
"xml"
"XMLEncodingMode"

3.2.1.4 IntradocDir/data/providers/provider_name/provider.hda

The following configuration variables are located in the provider.hda file in the IntradocDir/data/providers/provider_name/ directory. These variables define settings for Oracle Content Server providers.


"IsPrimaryUserBase"
"LdapAdminDN"
"LdapAdminPassword"
"LdapPort"
"LdapServer"
"LdapSuffix"
"NumConnections"
"Priority"
"ProviderClass"
"ProviderConfig"
"ProviderConnection"
"ProviderType"
"SourcePath"
"UseNetscape"
"UseSecureLdap"

3.2.3 Inbound Refinery Configuration Variables

The following configuration files are located in the Inbound Refinery installation directory (noted by IntradocDir/config/config.cfg).

Configuration variables returning a string that defines a directory or file path related to the Inbound Refinery will return that path relative to the Inbound Refinery installation directory. These paths are generally not recognizable to the Oracle Content Server system nor usable to the user if passed as information within an HTM page.


"AllowSecondaryConversion"
"AllowSkippedHyperlinktoCauseIncomplete"
"DefaultGraphicTimeout"
"DefaultNativeTimeout"
"DefaultPostscriptTimeout"
"DistillerPath"
"FileEncoding"
"FrameMakerCyclesAllowed"
"FrameMakerTimeout"
"IntradocDir"
"JvmCommandLine"
"MaxNumRecursiveStepDefinitions"
"MSPubexePath"
"OpenOfficeListenerPort"
"OpenOfficeListenerURL"
"PageMakerExePath"
"PostConversionTimeOut"
"PostprocessPDFPath"
"PostscriptPrinterName"
"PowerPointPrintOutput"
"PreconversionPath"
"PreconversionWaitTime"
"PrinterPortPath"
"ProcessExcelUrlHyperlinks"
"ProcessInDesignBookMarks"
"ProcessInDesignHyperlinks"
"ProcessInDesignInternalPDFThumbnail"
"ProcessInDesignLinkUpdate"
"ProcessInDesignPDFCompatibility50"
"ProcessPowerpointHyperlinks"
"ProcessVisioInternalHyperlinks"
"ProcessVisioUrlHyperlinks"
"ProcessWordBookMarks"
"ProcessWordComments"
"ProcessWordEmailLinks"
"ProcessWordFootEndNote"
"ProcessWordHeadings"
"ProcessWordHyperlinks"
"ProcessWordToc"
"ProcessWordUrlHyperlinks"
"SecondaryConversionStepName"
"VaultDir"
"VerboseMode"
"WeblayoutDir"

3.2.4 Link Manager Configuration Variables

The following variables are used to configure the Link Manager application. These variables are set in the IntradocDir/ucm/cs/bin/config.cfg file.


"AllowForceDelete"
"HasSiteStudio"
"LkDisableOnRebuild"
"LkDisableReferenceInfo"
"LkDisallowConversionFormats"
"LkIsSecureSearch"
"LkReExtractOnRebuild"
"LkRefreshBatchSize"
"LkRefreshErrorPercent"
"LkRefreshErrorsAllowed"
"LkRefreshErrorThreshold"

3.2.5 Pop-Up Calendar Configuration Variables

The following variables are used to configure the Pop-Up Calendar application. These variables are set in the IntradocDir/config/config.cfg file.


"pucDefaultTime"
"pucEnableOnSearch"
"pucHideTimeInDateFields"
"pucUseMonthLocale"
"pucUseWeekdayLocale"
"pucXOffset"
"pucYOffset"
"pucZIndex"

3.3 Dynamic Variables

A dynamic variable is evaluated on each occurrence of the variable. Thus, each time the variable is encountered the value is recalculated from code. (In contrast, a value variable is evaluated once at the beginning of the service call and that value is used throughout the service call. See Section 3.9, "Value Variables.") Dynamic variables generally return a value such as a string or an integer.

The following is a list of Idoc Script dynamic variables.


"AfterLogin"
"HttpIgnoreWebServerInternalPortNumber"

3.4 Environment Variables

Web server variables are the CGI environment variables that are set when the server executes the gateway program. In order to pass data about the information request from the server to the script, the server uses command-line arguments and environment variables. These environment variables can be used to output information to a log file or can be used within Idoc Script statements and as part of evaluations.

For example, this Idoc Script statement evaluates whether the remote host address matches a specific string:

<$if strEquals("207.0.0.1",REMOTE_HOST)$>

This HTML and Idoc Script markup displays a list of web server environment information on the page:

<P>HTTP_INTERNETUSER=<$HTTP_INTERNETUSER$></P>
<P>REMOTE_HOST=<$REMOTE_HOST$></P>
<P>SCRIPT_NAME=<$SCRIPT_NAME$></P>

The following is a list of web server variables.


"CONTENT_LENGTH"
"GATEWAY_INTERFACE"
"HTTP_ACCEPT"
"HTTP_ACCEPT_ENCODING"
"HTTP_ACCEPT_LANGUAGE"
"HTTP_COOKIE"
"HTTP_HOST"
"HTTP_INTERNETUSER"
"HTTP_REFERER"
"HTTP_USER_AGENT"
"PATH_INFO"
"PATH_INFO"
"QUERY_STRING"
"REMOTE_ADDR"
"REMOTE_HOST"
"REQUEST_METHOD"
"SCRIPT_NAME"
"SERVER_NAME"
"SERVER_PORT"
"SERVER_PROTOCOL"
"SERVER_SOFTWARE"

3.5 Global Functions

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.

The following is a list of Idoc Script global functions.


"abortToErrorPage"
"break"
"cacheInclude"
"clearSchemaData"
"computeDocUrl"
"computeRenditionUrl"
"dateCurrent"
"ddAppendIndexedColumnResultSet"
"ddAppendResultSet"
"ddApplyTableSortToResultSet"
"ddGetFieldList"
"ddIncludePreserveValues"
"ddLoadIndexedColumnResultSet"
"ddLoadResultSet"
"ddMergeIndexedColumnResultSet"
"ddMergeResultSet"
"ddMergeUsingIndexedKey"
"ddSetLocal"
"ddSetLocalByColumnsFromFirstRow"
"ddSetLocalByColumnsFromFirstRowIndexed"
"ddSetLocalEmpty"
"ddSetLocalEmptyByColumns"
"docLoadResourceIncludes"
"docRootFilename"
"docUrlAllowDisclosure"
"dpGet"
"dpPromote"
"dpPromoteRs"
"dpSet"
"encodeHtml"
"eval"
"executeService"
"forceExpire"
"formatDate"
"formatDateDatabase"
"formatDateDisplay"
"formatDateOnly"
"formatDateOnlyDisplay"
"formatDateOnlyFull"
"formatDateWithPattern"
"formatTimeOnly"
"formatTimeOnlyDisplay"
"getDebugTrace"
"getErrorTrace"
"getFieldViewDisplayValue"
"getFieldViewValue"
"getFreeMemory"
"getParentValue"
"getRequiredMsg"
"getTextFile"
"getTotalMemory"
"getUserValue"
"getValue"
"getValueForSpecifiedUser"
"getViewValue"
"getViewValueResultSet"
"hasAppRights"
"idocTestForInclude"
"inc"
"incDynamicConversionByRule"
"incGlobal"
"incTemplate"
"indexerSetCollectionValue"
"isActiveTrace"
"isFalse"
"isLayoutEnabled"
"isTrue"
"isUserOverrideSet"
"isValidateFile"
"js"
"jsFilename"
"lc"
"lcCaption"
"LmDefaultLayout"
"LmDefaultSkin"
"lmGetLayout"
"lmGetSkin"
"loadCollectionInfo"
"loadDocMetaDefinition"
"loadDocumentProfile"
"loadSchemaData"
"loadSearchOperatorTables"
"loadUserMetaDefinition"
"optList"
"parseDataEntryDate"
"parseDateWithPattern"
"pneNavigation"
"regexMatches"
"regexReplaceAll"
"regexReplaceFirst"
"rptDisplayMapValue"
"rs"
"rsAddFields"
"rsAddFieldsWithDefaults"
"rsAddRowCountColumn"
"rsAppend"
"rsAppendNewRow"
"rsAppendRowvalues"
"rsCopyFiltered"
"rsCreateReference"
"rsCreateResultSet"
"rsDeleteRow"
"rsDocInfoRowAllowDisclosure"
"rsExists"
"rsFieldByIndex"
"rsFieldExists"
"rsFindRowPrimary"
"rsFirst"
"rsInsertNewRow"
"rsIsRowPresent"
"rsLoopInclude"
"rsLoopSingleRowInclude"
"rsMakeFromList"
"rsMakeFromString"
"rsMerge"
"rsMergeDelete"
"rsMergeReplaceOnly"
"rsNext"
"rsNumFields"
"rsNumRows"
"rsRemove"
"rsRename"
"rsRenameField"
"rsSetRow"
"rsSort"
"rsSortTree"
"setContentType"
"setExpires"
"setHttpHeader"
"setMaxAge"
"setValue"
"setResourceInclude"
"stdSecurityCheck"
"strCenterPad"
"strCommaAppendNoDuplicates"
"strConfine"
"strEquals"
"strEqualsIgnoreCase"
"strGenerateRandom"
"strIndexOf"
"strLeftFill"
"strLeftPad"
"strLength"
"strLower"
"strRemoveWs"
"strReplace"
"strReplaceIgnoreCase"
"strRightFill"
"strRightPad"
"strSubstring"
"strTrimWs"
"strUpper"
"toInteger"
"trace"
"url"
"urlEscape7Bit"
"userHasAccessToAccount"
"userHasGroupPrivilege"
"userHasRole"
"utGetValue"
"utLoad"
"utLoadDocumentProfiles"
"utLoadResultSet"
"xml"

3.6 Page Variables

Page variables are set on a particular web page to enable specific page attributes or functionality. A page variable applies only to the page on which it is set.

This section includes the following topics:

3.6.1 Page Display Variables

Page variables that affect page display are typically set near the top of the page. Page display variables should be used as read-only variables; setting or changing the value of any of these variables will typically change the way all metadata is displayed on the page, which in most cases is not the desired effect.

The following is a list of Idoc Script page display variables.


"generateUniqueId"
"isCheckin"
"isDocPage"
"isEditMode"
"isFormSubmit"
"isInfo"
"isQuery"
"isUpdate"
"isUploadFieldScript"
"localPageType"
"noMCPrefill"

3.6.2 Field Display Variables

Field display variables can be grouped into the following types:

3.6.2.1 Field Information Variables

The following variables define information about a metadata field. The variable values are loaded or computed for each metadata field.


"fieldCaption"
"fieldDefault"
"fieldIsOptionList"
"fieldName"
"fieldOptionListType"
"fieldType"
"fieldValue"
"fieldWidth"
"isRequired"
"requiredMsg"
"valueStyle"

Example

The std_prepare_metafield_include include in the resource file named IdcHomeDir/resources/core/std_page.htm loads a number of field information variables from the local data in preparation for displaying the current metadata field.

<@dynamichtml std_prepare_metafield_include@>
<!--Prepare for presenting field-->
<$fieldName=dName, fieldCaption=dCaption, fieldDefault=dDefaultValue$>
<$fieldType=dType, fieldIsOptionList=dIsOptionList, fieldOptionListType=dOptionListType$>
<@end@>

3.6.2.2 Common Field Display Variables

There are several commonly used page variables that affect the display of metadata fields. These variables can be set using different syntaxes at different places on a page, depending on how they are being used.

The following formats can be used to set a special field display variable:

  • Name/Value pair: The variable is set using the standard variable=value format. For example, isHidden=1. This format is typically used to set the display of the current metadata field at the point in the page where the field is being generated by looped code.

  • FieldName:Variable format: The variable is set by defining it as a parameter for the metadata field it applies to. For example, myMetadata:isHidden. This format is typically used at the top of a page to set the global display of a particular metadata field.

If a common field display variable is set at the top of a template page, it should be placed before the <HEAD> tag. Placing the variable in or after the <HEAD></HEAD> section will result in the field being displayed (or not displayed) as you intended, but the JavaScript validation code in the header will still be evaluated, so an … is not an object error will be thrown when you attempt to display a checkin page.

The following is a list of the common field display variables.


"isExcluded"
"isHidden"
"isInfoOnly"
"isRelocated"
"maxLength"
"optionListScript"

If these common field display variables are not sufficient to provide the required flexibility, the entire implementation of a metadata field can be replaced by setting the field variable to the name of a resource include that should be used instead (for example, myField:include=customInclude).

The standard implementation is referred to by the variable defaultFieldInclude , whose value is different depending on whether the field is being generated on a checkin/update, query, or info page. It also varies considerably based on the type of field being displayed. If the standard field include is overridden, then the new implementation must take into consideration all the issues of the different pages, including JavaScript validation and the Upload applet.

Use this approach only as a last resort. It is preferable to extend existing functionality and set local variables to have custom functionality.


If you use the include tag in this way to insert custom HTML code for a special metadata field, you must place the include statement after the </HEAD> tag on the page. If you place it before the </HEAD> tag, the system will insert your custom HTML code into the header and attempt to read it as JavaScript.

3.6.2.3 Other Field Display Variables

A number of other variables are available to affect the display of metadata fields. Generally, these are used to define the display of a metadata field depending on which field is currently being generated and the value of related common field display variables. The following is a list of other field display variables.


"addEmptyOption"
"captionEntryWidth"
"captionFieldWidth"
"defaultFieldInclude"
"defaultOptionListScript"
"fieldCaptionInclude"
"fieldCaptionStyle"
"fieldEditWidth"
"fieldEntryInclude"
"fieldExtraScriptInclude"
"fieldInclude"
"fieldMaxLength"
"fieldValueStyle"
"hasOptionList"
"isFieldExcluded"
"isFieldHidden"
"isFieldInfoOnly"
"isFieldMemo"
"isMultiOption"
"isStrictList"
"NotationForRequiredFields"
"optionListKey"
"optionListName"
"optionListResultSet"
"optionListValueInclude"
"optionsAllowPreselect"
"StyleForRequiredFields"

Example

This example shows how the compute_std_field_overrides include in the IdcHomeDir/resources/core/templates/std_page.htm resource file determines if the field currently being generated is hidden, information only, excluded, and/or relocated. This code is looped over during generation of each metadata field on a page.

<@dynamichtml compute_std_field_overrides@>
<$isCustomHidden = getValue("#active", fieldName & ":isHidden")$>
<$if isHidden or isCustomHidden$>
    <$isFieldHidden = 1$>
<$else$>
    <$isFieldHidden = ""$>
<$endif$>
<$isCustomInfo = getValue("#active", fieldName & ":isInfoOnly")$>
<$if isInfo or isCustomInfo or isFieldHidden or isInfoOnly$>
    <$isFieldInfoOnly = 1$>
<$else$>
    <$isFieldInfoOnly = ""$>
<$endif$>
<$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$>
<@end@>

3.7 Read-Only Variables

Read-only variables can be used to gather information about the current template, the user who is currently logged in, or other current settings. These variables are read-only and cannot be assigned a value.

3.7.1 Template Read-Only Variables

Template-related read-only variables make it possible to create conditional content in a template based on the identity of the template. These pre-defined variables allow you to display the class, file path, name, or type of any template on an Oracle Content Server web page. This is particularly useful while you are developing your Web site.

The following read-only variables are related to templates.


"TemplateClass"
"TemplateFilePath"
"TemplateName"
"TemplateType"

3.7.1.1 Template Read-Only Variable Example

In this example, the internal name of the template appears under the Administration link in the left sidebar of all Oracle Content Server web pages. To accomplish this change, the pre-defined TemplateName variable was added to the pne_nav_admin_links include that defines the Administration links.

The following is an example of using the TemplateName pre-defined variable to display the internal template name on a web page.

<$if IsSubAdmin$>
<tr>
    <td>
        <a href="<$HttpCgiPath$>?IdcService=GET_ADMIN_PAGE&Action=
           GetTemplatePage&Page=ADMIN_LINKS"
        OnMouseOver="imgAct('admin')"
        OnMouseOut="imgInact('admin')">
        <img src="<$HttpImagesRoot$>
           <$button_admin_grey_ish_image$>" width="<$navImageWidth$>"         height="<$navImageHeight$>" name="admin" border="0"         alt="<$lc("wwProductAdministration", ProductID)$>"></a>
    </td>
        <td>
        <a class=pneHeader href="<$HttpCgiPath$>?IdcService=GET_ADMIN_
              PAGE&Action=GetTemplatePage&Page=ADMIN_LINKS"
        OnMouseOver="imgAct('admin')"
        OnMouseOut="imgInact('admin')">
        <$lc("wwAdministration")$></a>
    </td>
</tr>
<tr>
    <td colspan=2><font color=#FFFFFF style="Arial"
        size="-1"><$TemplateName$></font></td>
</tr>
<$endif$>

3.7.2 User Read-Only Variables

User-related read-only variables make it possible to gather information about the current user.

The following read-only variables are related to users.


"DelimitedUserRoles"
"ExternalUserAccounts"
"ExternalUserRoles"
"UserAccounts"
"UserAddress"
"UserAppRights"
"UserDefaultAccount"
"UserFullName"
"UserName"
"UserRoles"

3.7.3 Content Read-Only Variables

One content-related read-only variable, "SourceID", makes it possible to retrieve the Content ID of the current dynamic server page.

This variable returns the same value as ref:dID. See Section 2.6.4, "Referencing Metadata in Dynamic Server Pages."

3.7.4 Other Read-Only Variables

The following variable is set only as internal flags, so it can be retrieved but not set directly.


"SafeDir"

3.8 Setable Variables

Setable variables can be set within script or used within a CGI string. For example, the variable "ScriptDebugTrace" can be used as a parameter to a service call to display debug trace information on a page. Setting one of these variables can change the content of the page.

The following is a list of Idoc Script setable variables.


"ClientControlled"
"coreContentOnly"
"getCookie"
"HasLocalCopy"
"IsJava"
"IsSavedQuery"
"IsSoap"
"IsXml"
"isZoneSearchField"
"ScriptDebugTrace"
"ScriptErrorTrace"
"setCookie"

3.8.1 Workflows

Idoc Script includes predefined functions and variables that are used specifically for workflows.

For a detailed description of how workflows are implemented in Oracle Content Server, see Oracle Fusion Middleware Application Administrator's Guide for Content Server.

The following points summarize the use of Idoc Script in workflows:

  • Workflow jumps are initiated through the evaluation of Idoc Script that is defined for a particular step event (entry, update, or exit).

  • As a revision moves from step to step, the system creates a companion file that maintains information about the state of the revision in the workflow. Along with user-defined options, the system also maintains the history of what steps the revision has been to, the last entry time, and the number of times a revision has entered a particular workflow step.

    • Global state information is maintained as the revision moves from step to step.

    • Localized state information is stored with the step and becomes available when a revision is at that step.

  • The companion file uses keys to keep track of workflow state information. The syntax for a key is:

    step_name@workflow_name.variable=value
    

    For example, the following keys define the value of the entry count and last entry variables for the Editor step of a workflow called Marketing:

    Editor@Marketing.entryCount=1
    Editor@Marketing.lastEntryTs={ts '2002-05-28 16:57:00'}
    
  • All workflow script evaluation occurs inside a database transaction. The result is that any serious errors or aborts that are encountered cause no change to either the database or the companion file. This also means that no Idoc Script workflow function should take more than a negligible amount of time. Consequently, to trigger an external process, an Idoc Script function should be written to execute in a separate thread.

    Caution:

    If you are using Idoc Script or custom components to load workflow information into the local data, keep in mind that there is a risk of data pollution. This is particularly important if you are loading information for a different revision than the current one.

3.9 Value Variables

A value variable is evaluated once at the beginning of a service call and that value is used throughout the service call. The variable is then reevaluated on each new service call. In contrast, a dynamic variable is evaluated on each occurrence of the variable. For example, the value variable isNew evaluates whether the content item is new or a revision when performing a check in. That evaluation is used throughout the call to the checkin service.

The following is a list of Idoc Script value variables.


"AuthorAddress"
"BrowserVersionNumber"
"CURRENT_DATE"
"CURRENT_ROW"
"DocTypeSelected"
"DocUrl"
"DownloadSuggestedName"
"fileUrl"
"FIRSTREV"
"HasOriginal"
"htmlRefreshTimeout"
"htmlRefreshUrl"
"HttpAbsoluteCgiPath"
"HttpAbsoluteCgiRoot"
"HttpAbsoluteWebRoot"
"HttpAdminCgiPath"
"HttpBrowserFullCgiPath"
"HttpCgiPath"
"HttpCommonRoot"
"HttpEnterpriseCgiPath"
"HttpHelpRoot"
"HttpImagesRoot"
"HttpLayoutRoot"
"HttpRelativeAdminRoot"
"HttpRelativeCgiRoot"
"HttpSystemHelpRoot"
"HttpWebRoot"
"IsEditRev"
"IsFailedConversion"
"IsFailedIndex"
"isNew"
"IsNotLatestRev"
"MSIE"
"NoMatches"
"OneMatch"
"PageParent"
"ResultsTitle"
"StatusCode"
"StatusMessage"
"UseHtmlOrTextHighlightInfo"