Date post: | 20-May-2015 |
Category: |
Education |
Upload: | learnfungo |
View: | 483 times |
Download: | 0 times |
COLDFUSION AND OTHER TRAININGS FOR $0 AND $10
Visit us at : http://learnfungo.com
Cold Fusion
Getting Started with Cold Fusion…
What is ColdFusionColdFusion 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).
WHY COLD FUSION?
AdvantagesEase of DevelopmentRapid 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.
ColdFusion FlowAccessing a website
ColdFusion FlowExplained A web browser makes a request to a web server for a
template with a .cfm or .cfc extension (or another custom configured extension).
The web server receives the request and forwards it to the ColdFusion MX Application Server.
The ColdFusion MX Application Server parses the CFML template and processes the tags and functions accordingly, interacting with other services, such as data sources or mail servers, as necessary.
The ColdFusion MX Application Server combines its dynamic output with the static HTML and CSS (and JavaScript, if any) in the template and passes the whole page back to the web server.
The web server passes the dynamically generated content back to the client machine's web browser.
ABOUT DATA TYPES
Data TypesBooleanStringsNumbersDate/time objectsListsArraysStructuresQuery objects
ABOUT VARIABLES
Variables in CFMLVariable 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 can't contain spaces.
ColdFusion variable names aren't case sensitive.
Assigning Values to Variables<cfset x = 8> <cfset y = x+12> <cfset Name = “Ankur"> <cfset x = Name> <cfset Authenticated = true> <cfset TheDate =
DateFormat(Now( ),'mm/dd/yyyy')>
Variable ScopeLocalFormURLQueryFileCookieApplicationSessionClient
ABOUT EXPRESSIONS & OPERATORS.
Expressions<cfset x = 10*(3+2)>……
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 outTo 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
ABOUT CONDITIONAL PROCESSING.
Conditional Processingcfif, 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
COLDFUSION AND OTHER TRAININGS FOR $0 AND $10
Visit us at : http://learnfungo.com