Template Object Properties

Please refer to the following table for detailed description of Objects and their properties for use with Template Tags.

 

I. Objects

Project Description
CTRL Control Object
PROJ Project Object
MASTERDETAILS Master Details Object
CUSTOMSCRIPTS Custom Scripts Object
DB Database Object
TABLE Table Object
FIELD Field Object
LANG Language Object

Note:
You can view the object properties by opening your Project File with a text editor. Project file is an XML file, each object is represented by an XML node in the project file. The object properties are saved as attributes of the node. The property name is same as the attribute name.

 

II. Properties

You can use the standard dot notation to access properties of the objects.

Example

<!--##=PROJ.ProjName##-->

This line will write the project name in the output file.

CTRL Object

The CTRL Object points to the current control in control.xml that is being generated.

Property Description Data Type
CtrlId Control id (e.g. list, view, edit, etc.) String
CtrlType Control type (e.g. table, report, field, other, copy, etc.) String

 

PROJ Object

The PROJ Object points to the current project. You can access the current project properties by PROJ.PropertyName.

Property Description Data Type
ProjName Project name String
ProjVar Project variable String
SqlQuote SQL quote identifier (Square Bracket / Double Quote / Single Quote / Back Quote / None / Default) String
Cache Allow cache Boolean
CharSet Character set String
CSS External CSS file String
OutputNameType

Output file name option:
"" - No prefix or suffix
"Prefix" - Prefix with extension
"Suffix" - Suffix with extension

String
OutputNameExt Output file name extension name String
OutputNameLCase Output file name in lowercase Boolean
BodyTitle Body title description String
BodyFont Body font String
BodySize Body size String
BodyBgColor Body background color String
BodyTextColor Body text color String
BodyLnkColor Body link color String
BodyVLnkColor Body vlink color String
BodyALnkColor Body alink color String
BodyLeftMargin Body left margin Integer
BodyTopMargin Body top margin Integer
HeaderColor (v5.0+) Page header color String
HeaderLogo (v5.0+) Page header logo file name String
HeaderHeight (v5.0+) Page header height Integer
MenuColor (v5.0+) Page menu color String
FooterColor (v5.0+) Page footer color String
FooterFontColor (v5.0+) Page footer font color String
FooterText (v5.0+) Page footer text String
TblWidth Table width String
TblPadding Table padding Integer
TblBorder Table border Integer
TblSpacing Table spacing Integer
TblBgColor Table background color String
TblHdrFontColor Table header font color String
TblHdrColor Table header background color String
TblAltColor Table use alternate row color Boolean
TblAltColor1 Table alternate color 1 String
TblAltColor2 Table alternate color 2 String
Template Template file location String
Destination Output destination folder location String
SecType Security type:
"None" - no security
"Hard Code" - use hard coded administrator login / password
"Use Table" - use security table
"Both" - Use both security table & hard coded administrator login / password
String
SecLoginID Administrator login id String
SecPasswd Administrator password String
SecTbl Security table name String
SecLoginIDFld Security table login id field name String
SecPasswdFld Security table password field name String
SecEmailFld Security table email field name String
SecForgetPwdPage Generate forget password page Boolean
SecChangePwdPage Generate change password page Boolean
SecChangeEmail Send email for password change Boolean
SecRegisterPage Generate registration page Boolean
SecRegisterConfirm (v5.0+) Registration page needs confirm Boolean
SecRegisterCaptcha (v5.0+) Registration page uses captcha Boolean
SecRegisterActivate (v5.0+) Registration page needs activation Boolean
SecRegisterActivateFld (v5.0+) Registration page activation field name String
SecLogInOutAuditTrail (v5.0+) Login / logout page needs audit trail Boolean
SecRegisterEmail Send email for registration Boolean
SecSenderEmail Sender email address String
SmtpServer Smtp server name String
SmtpServerPort Smtp server port Long
MemoCRLFReplace Replace CRLF with BR for Memo Field Boolean
ServerScriptTimeout Server script timeout time for reports Integer
DefaultDateFormat Default date format:
0 - General date (system)
1 - Long date (system)
2 - Short date (system)
3 - Long time (system)
4 - Short time (system)
5 - "yyyy/mm/dd"
6 - "mm/dd/yyyy"
7 - "dd/mm/yyyy"
8 - Short date + short time
9 - "yyyy/mm/dd hh:nn:ss"
10 - "mm/dd/yyyy hh:nn:ss"
11 - "dd/mm/yyyy hh:nn:ss"
12 - "hh:nn:ss"
Integer
DateSeparator Date separator: "/", "-", "." String
XMLEncoding XML encoding charset String
HighlightColor List page row highlight color String
SelectColor List page row select color String
EditBackColor List page edit row background color String
PagerBackColor Pager background color String
FooterBackColor Footer (aggregated values) background color String
UploadPath File upload path String
UploadAllowedFileExt Allowed upload file extensions String
CssStyles User css style content String
AutoSync Auto synchronize when open project Boolean
CreateVDir Create virtual directory after generation Boolean
AutoBrowse Auto browse after generation Boolean
OtherGen Generate other scripts Boolean
OtherOverwrite Overwrite other scripts Boolean
PromptOnOverwrite Prompt on overwrite Boolean
DynamicLoadDB Load database dynamically Boolean
OptionExplicit Use PHP "option explicit" option Boolean
RptIndent Report header indentation in pixels Integer
RecPerPage Records per page Integer
RecPerPageList Comma separated values for records per page (list page only) String
ExportHtml Export to html Boolean
ExportWord Export to word Boolean
ExportExcel Export to excel Boolean
ExportXml Export to xml Boolean
ExportCsv Export to csv Boolean
RecPerRow Records per row (multi-column list page) Integer
MultiDelete Delete records by multiple selection Boolean
Sort Type Sort type
0 - no sort
1 - single column sort
2 - multi-column sort
Integer
PagerStyle Pager style:
1 - numeric pager
2 - nextprev pager
Integer
TopPageLink Pager on top Boolean
BottomPageLink (v5.0+) Pager on bottom Boolean
ViewExport (v5.0+) View page export Boolean
LinkOnLeft Links on Left Boolean
InlineDelete Inline delete Boolean
DetailViewPaging (v5.0+) Paging in view page Boolean
AppRootFolder Application root folder String
RepeatColumns Repeat column count for radios and checkboxes Integer
RecipientEmail Receiver email String
DeleteUploadedFile Delete unused uploaded file Boolean
SMTPServerUsername Smtp server user name String
SMTPServerPassword Smtp server password String
ShowBlankListPage Show blank list page String
AuditTrailPath Audit trail path String

 

Master Details Object

The Master Details Object contains the collection of all master/detail relationships defined in the current project. Each master/detail relationship has the following properties.

Property Description Data Type
MasterTable Master table name String
DetailTable Detail table name String
FieldCount Total number of master/detail key pairs Integer
CurrentField Current master/detail field key pair position Integer
CurrentMasterField

Current matser field key

String
CurrentDetailField Current detail field key String

 

Custom Scripts Object

The Custom Scripts Object contains the collection of all custom scripts defined in the current project. Each custom script has the following properties.

Property Description Data Type
ScriptType Script type (Server/Client) String
ScriptCodeType Script code type (Global/Table/Other) String
ScriptName Script name String
ScriptCtrlID Script control id String
ScriptL1Key

Script level 1 key (table/other name)

String
ScriptL2Key Script level 2 key (reserved for future use) String
ScriptCode Custom script code String

 

DB Object

The DB Object points to the current database. You can access the current database properties by DB.PropertyName.

Property Description Data Type
DBName Database name String
DBType Database type String
DBPath Database path String
DBHost Database host String
DBPort Database port String
DBUID Database user id String
DBPwd Database password String
DBQuoteS Database start quote character String
DBQuoteE Database end quote character String
DBConnstr Database connection string String
DBDBMSName DBMS name String
DBDBMSVer DBMS version String
DBProviderName Provider name String
DBProviderVer Provider version String
MaxUploadSize Maximum upload file size Integer
SecUserLevelFld User level field name String
SecDefault Default security setting String
SecuUserIDFld User id field name String
UseDynamicUserLevel Use dynamic user level Boolean
UserLevelTbl User level table name String
UserLevelIdFld User level id field name String
UserLevelNameFld User level name field name String
UserLevelPrivTbl User level privilege table name String
UserLevelPrivTblNameFld User level table name field name String
UserLevelPrivUserLevelFld User level user level name field name String
UserLevelPrivPrivFld User level privilege field name String
SecuParentUserIDFld Parent user id field name String

 

TABLE Object

The TABLE Object points to the current table. You can access the current table properties by TABLE.PropertyName.

Property Description Data Type
TblName Table name String
TblType Table type (TABLE/VIEW/CUSTOMVIEW/REPORT) String
TblKey Table key String
TblGen Generate this table Boolean
TblList Show table in menu Boolean
TblView

Table view enabled

Boolean
TblInlineEdit

Table inline edit enabled

Boolean
TblGridEdit (v5.0+) Table grid edit enabled Boolean
TblEdit Table edit enabled Boolean
TblEditConfirm (v5.0+) Edit needs confirmation Boolean
TblAdd Table add enabled Boolean
TblAddConfirm (v5.0+) Add needs confirmation Boolean
TblAddCaptcha (v5.0+) Add use captcha Boolean
TblInlineAdd (v5.0+) Table inline add enabled Boolean
TblInlineCopy (v5.0+) Table inline copy enabled Boolean
TblMultiUpdate (v5.0+) Table multi-update enabled Boolean
TblMultiUpdateConfirm (v5.0+) Multi update needs confirmation Boolean
TblAnonymous (v5.0+) Table anonymous access security Integer
TblDelete Table delete enabled Boolean
TblCaption Table caption String
TblVar

Table variable name

String
TblSrchType Table search type:
"NONE" - none
"BASIC" - basic search
"ADVANCED" - advanced search
"BOTH" - both basic & advanced search
String
TblSearchHighlight (v5.0+) Search highlight Boolean
TblSearchColor (v5.0+) Search highlight color String
TblDefault Table link from default page Boolean
TblCopy Table copy enabled Boolean
TblFilter Table filter (sql where clause) String
TblUserIDFld Table user id field name String
TblSecurity Table security settings String
TblOverwrite Overwrite table scripts Boolean
TblLoaded Table is loaded Boolean
TblRptShowDetails Show report details (reports only) Boolean
TblRptShowGrandTotal Show report grand total (reports only) Boolean
TblCustomSQL Table custom sql (custom views only) String
TblCustomError Error loading custom views / reports String
TblRptSrc Report source table (reports only) Boolean
TblRptIndent Report indentation by pixels (reports only) Integer
TblUseGlobal Use global settings Boolean
TblRecPerPage Records per page (list page only) Integer
TblRecPerPageList Dynamic values for records per page (list page only) String
TblExportHtml Export to html Boolean
TblExportWord Export to word Boolean
TblExportExcel Export to excel Boolean
TblExportXml Export to xml Boolean
TblExportCsv Export to csv Boolean
TblRecPerRow Records per row (multi-column list page) Integer
TblMultiDelete Delete records by multiple selection Boolean
TblSort Type Sort type
0 - no sort
1 - single column sort
2 - multi-column sort
Integer
TblPagerStyle Pager style:
1 - numeric pager
2 - nextprev pager
Integer
TblTopPageLink Pager on top Boolean
TblBottomPageLink (v5.0+) Pager on bottom Boolean
TblViewExport (v5.0+) View page export Boolean
TblLinkOnLeft Links on Left Boolean
TblInlineDelete Inline delete Boolean
TblDetailViewPaging (v5.0+) Paging in view page Boolean
TblAuditTrail Table use audit trail Boolean
TblSendMailOnAdd Send email on add Boolean
TblSendMailOnEdit Send email on edit Boolean
TblSendMailOnDelete Send email on delete Boolean
TblShowBlankListPage Show blank list page Boolean

 

FIELD Object

The FIELD Object points to the current field. You can access the current field properties by FIELD.PropertyName.

Property Description Data Type
FldName Field name String
FldAlias Field alias name String
FldSourceName Field source name String
FldSourceTable Field source table name String
FldSourceField Field source field name String
FldType Field data type Integer
FldSupport Field is supported Boolean
FldSize Field size Long
FldUniqueIdx Field has unique index Boolean
FldZeroLen

Field support zero-length string
(For Access database only)

Boolean
FldReq Field is required (NOT NULL) Boolean
FldIsPrimaryKey Field is primary key Boolean
FldAutoIncrement Field is auto increment field Boolean
FldAttribute Field ADO attributes Long
FldMin Minimum value for javascript validation Variant
FldMax Maximum value for javascripot validation Variant
FldErrMsg Error message if javascript validation failed String
FldValidate Validate format for javascript String
FldRequired Required field for javascript validation Boolean
FldPopCalendar Use popup calendar Boolean
FldGenerate Field generate enabled Boolean
FldList Field list enabled Boolean
FldView Field view enabled Boolean
FldEdit Field edit enabled Boolean
FldAdd Field add enabled Boolean
FldSearch Field search enabled Boolean
FldBasicSearch Field basic search enabled Boolean
FldExtendedBasicSearch Field extended basic search enabled Boolean
FldRegister Field enabled for registration page Boolean
FldSrchOpr Field search operator String
FldSrchOpr2 Field second search operator String
FldDefault Field default value Variant
FldCaption Field caption String
FldVar Field variable String
FldViewTag Field view tag String
FldViewThumbnail (v5.0+) Field view as thumbnail (FILE type field only) Boolean
FldHtmlTag Field html tag String
FldHtmlTagReadOnly

Field is read only

Boolean
FldTagSize Field html tag size Integer
FldTagMaxLength Field html tag maximum length Integer
FldTagHiddenValue Custom value for hidden tag String
FldSelectType Field select type (Table/Values) String
FldTagValues Field value list String
FldTagLnkTbl Field link to table name String
FldTagLnkFld Field link to table key field name String
FldTagLnkDisplay Field link to table display field name String
FldTagLnkDisp2 Field link to table display field 2 name String
FldTagLnkOrderBy Field link to table order by field name String
FldTagLnkOrderType Field link to table order type (ASC/DESC) String
FldTagLnkDistinct Field link to table use distinct value Boolean
FldTagCols Field column count (TEXTAREA) Integer
FldTagRows Field row count (TEXTAREA) Integer
FldTagImgWidth Image width (IMG) Integer
FldTagImgHeight Image height (IMG) Integer
FldTagAType Href type String
FldTagATarget Href target type (A) String
FldTagAPrefix Href prefix (A) String
FldTagASuffix Href suffix (A) String
FldBold Field bold enabled Boolean
FldItalic Field italic enabled Boolean
FldAlign Field alignment String
FldFmtType Field format type:
"Currency" - format as currency
"Date/Time" - format as date/time
"Number" - format as number
"Percent" - format as percent
"String" - format as string
String
FldDtFormat Field date format:
See PROJ.DefaultDateFormat for details
Integer
FldNumDigits Field number of digits after decimal Integer
FldIncLeadDigit Field include leading digit Integer
FldUseParen Field use parenthesis for negative Integer
FldGpDigits Field group digits Integer
FileNameFld File name field name (FILE) String
FileTypeFld File type field name (FILE) String
FileSizeFld File size field name (FILE) String
ImageWidthFld Image width field name (FILE) String
ImageHeightFld Image height field name (FILE) String
FldHrefFld Field hyperlink to field name String
FldHrefFldOrig (v5.0+) Href use original value Boolean
FldStrFunc Field string function name String
FldUseDHTMLEditor Use DHTML editor (MEMO) Boolean
FldMemoMaxLength Maximum length for memo field (list page only) Integer
FldSelectSize Multiple selection list size Integer
FldSelectMultiple Use multiple selection list Boolean
FldSelectFilter Field select filter String
FldSelectFilterFld Dynamic combobox filter field name String
FldParentSelect Dynamic combobox parent field name String
FldSelectAllowAdd Ajax add to combo box Boolean
FldQuoteS Field start quote character String
FldQuoteE Field end quote character String
FldColumnWidth List page field column width String
FldColumnWrap List page field column wrap Boolean
FldAggregate Field aggregation function name String
FldGroupBy Field grouping sequence (reports only) Integer
FldGroupByShowSummary Field grouping show summary (reports only) Boolean
FldOrderBy Field ordering sequence Integer
FldOrder Field order type (ASC/DESC) String
FldRptAggSum Aggregate field sum (reports only) Boolean
FldRptAggAvg Aggregate field average (reports only) Boolean
FldRptAggMin Aggregate field minimum (reports only) Boolean
FldRptAggMax Aggregate field maximum (reports only) Boolean
FldRepeatColumns Repeat column count for radios and checkboxes Integer
FldUploadPath Field level upload path String
FldCheckDuplicate Check duplicate for field Boolean
FldPageIndex Field page index (multi page add/edit) Integer
FldAjax Field use Ajax Boolean
FldAutoUpdateValue (v5.0+) Field auto update value String
FldUploadResize (v5.0+) Resize file on upload (FILE) Boolean
FldResizeWidth (v5.0+) Resize file width Integer
FldResizeHeight (v5.0+) Resize file height Integer
FldResizeQuality (v5.0+) Resize file quality (for JPEG only, 0-100) Integer
FldMultiUpdate (v5.0+) Field enabled multi-update Boolean
FldTitle (v5.0+) Field title attribute (INPUT) String
FldAlt (v5.0+) Field alt attribute (IMG) String
FldEditCustomAttributes (v5.0+) Field edit tag custom attributes String
FldViewCustomAttributes (v5.0+) Field view tag custom attributes String

 

LANG Object

Method Description Returns
Phrase Method to retrieve a phrase in the language file String
AddPhrase(id, phrase) (v5.0+) Method to add new phrase. Return false if phrase already exist. Boolean
ReplacePhrase(id, phrase) (v5.0+) Method to replace phrase, Return false if phrase not exist Boolean

 

Note that this object is different from above objects. There are only methods, no properties. To access the language object, use the following syntax:

LANG.Phrase

Example

<!--##=LANG.Phrase("BackToFile")##-->

This is equivalent to:

<!--##@BackToList##-->

This line outputs the phrase "BackToList" as defined in the lang.xml. If the lang.xml file contain the node:

<phrase id="BackToList" value="Back to List"/>

The line write "Back to List" to the output file.

 

 


 ©2002-2007 e.World Technology Ltd. All rights reserved.