Coldfusion是一个用Java编写的脚本处理服务器。 Coldfusion需要一个Java服务器(如JRun),一个Web服务器(如Apache)以及Coldfusion 9之前的数据库服务器(如果您要使用数据库)。幸运的是开发版附带了所有内置的功能。
对于生产,您需要一个单独的Web服务器,如IIS或Apache,因为内置的Web服务器仅限于开发。您很可能需要一个单独的数据库服务器,例如MySQL或Microsoft SQL。但除非您有特定的需求,否则您可能会与内置的JRun Java服务器相处,现在不用担心Coldfusion的这一方面。
如果你做任何PHP,ColdFusion的将是方式有点类似于它是服务器以及如何代码和HTML的脚本页面集成在一起的设置。 (是的,有分歧,但是这是一个足够好的比较,而不是与.NET安装程序)
ColdFusion的有它自己的内置数据库,或者你可以从各种各样的其他数据库的选择。你应该建立一个到数据库的连接,在ColdFusion管理员中称为'数据源',然后在使用cfquery标签之后使用真的很简单。
如果您不熟悉ColdFusion,我想直到你有ColdFusion和您现有的应用程序是如何工作的第一个好的手柄跳过所有的第三方框架。如果你是新手,这些都会增加不必要的复杂性,并且框架的文档有点稀疏。
查看源代码。在这里询问关于它的含义的个别问题。
找到一个特定的ColdFusion的功能的文档最快的方法是到谷歌:
'ColdFusion的8 cftagname'(如 'ColdFusion的8 CFQUERY' 或 'ColdFusion的8 cfqueryparam')
或
'Coldfusion 8 cffunctionname'(例如'Coldfusion 8 structKeyExists')
单击生成的livedocs.adobe.com链接。 (谷歌的工作方式比网站的内部搜索引擎更好,而Coldfusion 8似乎是与Google最好的链接)
cfdump标签对于简单的调试非常方便。
最后,这里的Hello World的例子:
index.cfm(标准ColdFusion的页面使用.CFM扩展)
<!--- All coldfusion tags begin with <cf
...and Coldfusion comments have three dashes.
These comments will be removed on the server side
before being sent to the browser
--->
<!--- Set a greeting variable using standard cfset tag --->
<cfset greeting = "Hello World!!">
<!--- Begin HTML --->
<html>
<head>
</head>
<body>
<!-- Normal HTML comment -->
<p>I could just say hello world with HTML</p>
<!--- In order to output Coldfusion within HTML,
wrap with the cfoutput tag. Variables in HTML are wrapped with hash marks:
Example: #varName#
--->
<cfoutput>
<p>More HTML, blah, blah, blah...</p>
<!--- Outputs: Hello World! --->
<p>#greeting#</p>
<!--- Or apply a Coldfusion function to the variable.
Wrap the variable name with a function name and
then wrap the function with hash marks to tell
the Coldfusion server to process the statement
--->
<!--- Outputs: HELLO WORLD! --->
<p>#ucase(greeting)#</p>
</cfoutput>
<!--- And another way to view the contents of a variable as a developer --->
<cfdump var="#greeting#>
<body>
</html>
希望有所帮助。
请打破这一成独立的问题。 – 2010-01-27 01:45:44
@丹:他们似乎有点太基本,不能保证自己的问题。我只需要一些指导来指导我,而不是过分担心每个细节是否得不到解答。 – mpen 2010-01-27 02:00:28