What is ColdFusion ColdFusion is “A rapid server scripting environment for creating rich internet applications." ColdFusion is a Web Application Server that executes scripts which are written in CFML (ColdFusion Markup Language).
Advantages Ease of Development Rapid application development (RAD). ColdFusion abstracts complex, low- level programming tasks, such as establishing connectivity with a mail server or querying a database, with simple HTML-like tags. Available for a broad range of popular operating systems and web servers.
Variables in CFML Variable names must begin with a letter, an underscore, or the Unicode currency symbol ($) and can contain only letters, numbers, underscores, and Unicode currency symbols. Variable names cant contain spaces. ColdFusion variable names arent case sensitive.
Assigning Values toVariables <cfset x = 8> <cfset y = x+12> <cfset Name = “Ankur"> <cfset x = Name> <cfset Authenticated = true> <cfset TheDate = DateFormat(Now( ),mm/dd/yyyy)>
OperatorsArithmetic : Performs arithmetic operations such as sign changes, addition, subtraction, etc., on numeric values.Comparison: Compares two values and returns a Boolean true/false.String: There is only one string operator in the CFML language. The ampersand (&) concatenates strings.Boolean: Also known as logical operators, Boolean operators perform connective and negation operations and return Boolean true/false values.Live Example
Blurting it out To output the contents or results of a ColdFusion expression, we use <cfoutput> tag. cfoutput is a paired tag, which means that it has both start and end tags. Live Example
Conditional Processing cfif, cfelseif, and cfelse <cfif expression> HTML and CFML... <cfelseif expression> HTML and CFML... <cfelse> HTML and CFML... </cfif>
Continue… cfswitch, cfcase, and cfdefaultcase <cfswitch expression="expression"> ◦ <cfcase value="value_or_list_of_values"> HTML and CFML... ◦ </cfcase> ◦ <cfcase value="value_or_list_of_values"> HTML and CFML... ◦ </cfcase> ... ◦ <cfdefaultcase> HTML and CFML... ◦ </cfdefaultcase> ◦ </cfswitch> Live Example
Visit us at :http://learnfungo.comCOLDFUSION ANDOTHER TRAININGS FOR$0 AND $10