ColdFusion is a set of Web development products developed by Allaire, which has recently merged with Macromedia.
The ColdFusion development environment makes it easy for you to build dynamic Web sites and Internet applications. With ColdFusion, you can develop a site or application that pulls data from a content database and then use templates to dynamically create Web site pages using the content stored in your database. ColdFusion is often used to build ecommerce sites.
ColdFusion enables you to perform tasks such as:
Query existing database applications for data.
Create dynamic queries facilitating more flexible data retrieval.
Execute stored procedures in databases.
Enhance the standard HTML form capabilities with data validation functions.
Dynamically populate form elements through database retrieval.
Customize the display dates, times and currency values with formatting functions.
ColdFusion includes ColdFusion Studio, which you can use to design and develop your templates, and ColdFusion Server, which interacts with relational databases and serves the Web pages to your users.
Because ColdFusion integrates its code (CFML) with standard HTML code, you can use any standard Web development application or a text editor to develop your templates. However, if you plan on building a large or complex site, you may find it helpful to use ColdFusion Studio.
NetNation runs ColdFusion MX Version 6.1.
ColdFusion works with ODBC-compliant databases. With NetNation's ColdFusion plans, you can use a Microsoft FoxPro, Microsoft Access or Microsoft SQL Server database. ColdFusion supports both DSN and DSN-less connections.
When discussing ColdFusion, RDS stands for Remote Development Services. Because RDS is not designed for a shared hosting environment, it presents a high security risk and is not enabled on NetNation's shared servers.
If you need a custom tag installed, contact NetNation support via your AccountManager.
Your ColdFusion scripts can be placed anywhere in your /www directory. The extensions *.cfm and *.dbm are mapped to the ColdFusion script engine.
You can place your custom ColdFusion tags (.cfm) in any directory under
your /www directory. Once you have uploaded your files, you will need
to use the CFMODULE tag to specify the location of your .cfm tags.
Yes. NetNation supports both CFX and CFFILE tags.
Because your site is pulling content from your database, it is not advisable to FTP your new database over your existing database. Instead, you should upload your new database with a different name. Once it is uploaded and you have made all the necessary changes, you can rename it to the correct name and remove your out-of-date database.
ColdFusion MX uses the J2EE (Java 2 Platform, Enterprise Edition) infrastructure for many of its base services. This enables you to easily integrate J2EE and Java functionality into your ColdFusion applications. For example, you can:
Use custom JSP (Java Server Pages) tags from JSP tag libraries
Interoperate with JSP pages
Use Java servlets
Use Java objects, including J2EE Java API, JavaBeans and Enterprise JavaBeans.
While you can use ColdFusion and ASP within the same site, it is difficultand not recommendedto use both within the same page.
The default setting (and maximum value) for session variables is 20 minutes.
The default setting (and maximum value) for application variables is 2 days.
The CFHTTP tag does not work as described in the ColdFusion Manual due to security restrictions in a shared environment. Specifically, if the METHOD attribute is set to "GET" then the #CFHTTP.FileContent#variable cannot be used to retrieve data extracted with CFHTTP.
You can work around this problem by using the PATH and FILE attributes to specify where the file should be created. Instead of using the CFHTTP.FileContent variable, read the downloaded file using CFFILE tag from the location specified in the CFHTTP PATH attribute. You may want to use a special directory for the PATH to these temporary files, as you will need to grant write access to the directory.
Once you have created an ODBC Data Source Name for your database, you can use CFQUERY:
<CFQUERY Name="myqueryname" DATASOURCE="DSNName" USERNAME="username" PASSWORD="password">
To send an email from a ColdFusion application, you use the CFMail tag. The following sample code illustrates how you can send a confirmation email to a visitor:
<CFMAIL to="#ContactEmail#" from="From Email" Subject="The Subject">
Thank you for your message,
We'll be in touch as soon as we can. Thanks for visiting our site,
Message By: #ContactName# - #ContactEmail#
If you are receiving this error, make sure that you have created the DSN. You should also check for any spelling errors.
This error indicates that the ODBC driver can not find the file in the location it expected. To try and resolve this problem, perform the following steps:
Ensure that you have created the data files.
Check the ODBC source settings and spelling.
If the file has been moved, manually update the file location information for any ODBC sources that reference the file.
Check that the database file defined by the DSN has not been renamed.
Parameter errors occur when a SQL statement references a field name that does not exist in the data source. You should check the SQL statement or query indicated in the error message and verify that:
You are using the correct data source with the query.
The fields exist and you have spelled their names correctly.
Any literals or strings in the query are enclosed in single quotes.
There are a number of resources that can help you as your work with ColdFusion, including:
© 2003 NetNation Communications