Intrinsic Conversions
Username:  
Password:
  > Home
> User Guide
v Reference
    > Introduction
    > CROFT
    v BEE Variables
       > BEE Variable Name
       o BEE Variable Value
       v BEE Conversions
          o Intrinsic Conversions
          o User-defined Conversions
          o To string or not to string
    > BEE Syntax
    > BEE Commands
    > Database Operation
    > Content Management
    > Objects and Classes
    > Interface with others
    o Glossary
> Portal Object
> Development Guide


Shortcuts
sys Class
debug Class
Intrinsic Conversions
>> Reference >> BEE Variables >> BEE Conversions >> Intrinsic Conversions <=  =>      <  1  2  3  4  5  6  >  
t to w Conversions built into BEE

Conversion

Input Type

Output Type

Description

tolower

String

String

Same as "lowercase"

toproper

String

String

Same as "propercase"

toupper

String

String

Same as "uppercase"

trim

String

String

Trim the leading and trailing white spaces from the input string.

translate

String

String

Take the array specification in the argument string (in the form of comma-delimited list of [key=>]value) and use the input string as an array index (the code) to find the corresponding value (the translated text), and return the value.

truncate

String

String

Take the argument string as a comma-delimited list of two arguments.  The first argument is a number indicating the length which the truncation will occur if the input string is longer than.

The optional second argument specifies a trailer to append to the end of the result if the truncation did occur.  e.g. the Conversion of "truncate:10,..." will turn "This is an apple." to "This is an...".

unescape

String

String

Remove backslashes ('') from the input string unless it is the last character.

unique

Array

Array

Remove all duplicated values from the input array and return the result array.

unless

String or Array

String or Array

Take the argument string as a comma-delimited list of two arguments.  The first argument is a logical expression representing a condition.  If the condition evaluates to false, return the original input string unchanged.  Otherwise, return the second argument.

The second argument is sometimes called the fallback value, when the condition is met.

If the input is an array, the second argument and onwards will form the "fallback array", which will be returned when the condition evaluates to true.

unshift

Array

Array

Append the argument string to the input array and return the result array.

The input array is passed by reference.  It will get an extra element at the beginning after this operation.

uppercase

String

String

Convert a all letters in a string to uppercase.

urlargstrip

String

String

Strip from the input string the first occurrence of the question mark ('?') and everything afterwards.

urldecode

String

String

Convert all occurrences of a percentage sign ('%') followed by two hexadecimal digits into their corresponding literal characters.

urlencode

String

String

Convert all non-alphanumeric characters into a percentage sign ('%') followed by two hexadecimal digits, with the exception of hyphen ('-'), underscore ('_') and dot ('.').

value

Array

Array

Return an array which contains all the values of the input array.  The index of the output array starts from 0 (for the first element that contains the first key of the input array).

values

Array

Array

Same as "value"

verb

String

String

Take the input string as an English verb and convert it into a form specified in the argument string, which can be

do:      return the input string (no conversion)

doing: convert ~ or ~e into ~ing

did:     convert ~ or ~e into ~ed

done:  convert ~ or ~e into ~ed

be:      return "are" if the input string is 0 or a number greater than 1 or less than 1.  Otherwise, return "is".

where ~ represents the verb in the input string.

word

String

String

Separate joint words by insert a space before each capital letter or '@' sign.  All caps string (e.g. acronyms) are recognised as one word.

words

String

String

Same as "word"

Previous Page       Next Page

Accsoft Computer Technology Pty Ltd     ABN: 98 065 617 549
PO Box 892, Epping NSW 1710         Level 1, Epping Office Park, 242 Beecroft Rd, Epping NSW 2121, Australia
Tel: Sydney - (02)98691668     National - 1300-881668         Fax: (02)98691866
© Copyright 2003 Accsoft Computer Technology Pty Ltd