gpt4 book ai didi

coldfusion - 这些 ColdFusion 组件之间有什么区别吗?

转载 作者:行者123 更新时间:2023-12-02 17:27:43 24 4
gpt4 key购买 nike

我知道结果是一样的,但是有什么真正的区别吗?也许是速度之类的?

component {

remote function getMath(){

math = 2 + 2;

return math;
}

}

<cfcomponent>

<cfscript>

remote function getMath(){

math = 2 + 2;

return math;
}

</cfscript>

</cfcomponent>

<cfcomponent>

<cffunction name="getMath" access="remote">

<cfscript>

math = 2 + 2;

return math;

</cfscript>

</cffunction>

</cfcomponent>

最佳答案

不是特别。

版本 3,完整标签,将向后兼容 ColdFusion 8 和 ColdFusion 服务器的开源版本,例如。 Railo 或 OpenBD。

版本 2 既不是什么也不是什么。

版本 1 是完整的 ColdFusion 9 脚本版本。

我建议您在第一个版本和最后一个版本之间进行选择并坚持使用。版本 2 不向后兼容 Coldfusion 8,并且既不是标签也不是脚本。这样的编码很快就会变得困惑。

关于coldfusion - 这些 ColdFusion 组件之间有什么区别吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/8781384/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com