IsBinary

Description

Determines whether a value is stored as binary data.

Return value

True, if the value is binary; False, otherwise. Returns the value in Base64 format.

Category

Decision functions

Syntax

IsBinary(value) 

See also

ToBinary, ToBase64, IsNumeric, YesNoFormat

Parameters

Parameter Description
value
Number or string

Example

<!--- This example shows the use of IsBinary. It assumes that another page in a
syndication program passed this page the value of the variable data_var,
which can hold character or binary data. This example checks whether
data_var is binary; if so, it converts the data to Base64 data. --->
<h3>IsBinary Example</h3>

<!--- Check whether syndicated data is in binary form. If so, convert to Base64
so it can be viewed as printable characters. --->
<cfif IsBinary(data_var)>
  <cfset Base64data = ToBase64(data_var)
</cfif>

Comments