Adobe 38000827 - Macromedia ColdFusion MX Standard Edition Evaluator Manual page 19

Evaluator guide
Hide thumbs Also See for 38000827 - Macromedia ColdFusion MX Standard Edition:
Table of Contents

Advertisement

Macromedia® ColdFusion® MX Evaluator's Guide
Publishing Web Services in ColdFusion MX
ColdFusion MX also makes it easy to expose functionality built in ColdFusion as a web
service. Once a method is exposed as a web service, it can be invoked by another
ColdFusion application or by any other technology that supports the SOAP standard for
web services, such as ASP.NET, Java, or PHP. As a result, developers using other
technologies can take advantage of functionality built by ColdFusion developers without
having to know ColdFusion itself.
Creating or publishing web services in ColdFusion MX is done through ColdFusion
components. Making a ColdFusion component available as a web service takes only a
single step. In the example below, setting the access parameter to "remote" tells the
ColdFusion MX environment to make this function available as a web service.
<cfcomponent>
<cffunction name="sayHello" access="remote">
</cffunction>
</cfcomponent>
When the ColdFusion MX environment encounters the "remote" keyword, it automatically
generates the web services description language (WSDL) files for the method. This XML-
based document is the interface specification that enables a remote client to understand
and invoke the service. Using this information, a developer could invoke the sayHello web
service from any technology that supports web services. In addition, a developer using
Dreamweaver MX could browse the web service and build an application that invokes it
by simply dragging the method into the code editor.
In addition to ease of use, the approach to web services offered in ColdFusion MX also
enables developers the flexibility to adopt web services gradually. Even if they are not
ready to start using web services today, by building applications using ColdFusion
components, they can easily add this capability later – without having to re-architect their
application or write additional code.
<cfoutput>Hello World!</cfoutput>
19

Advertisement

Table of Contents
loading

This manual is also suitable for:

Macromedia coldfusion mx

Table of Contents