Application.cfcのは、組み込み変数
-
19-09-2019 - |
質問
ColdFusionのバージョン9では、私がindex.cfmにして、次のしている:
<cfdump var="#Application#">
しかし、私は戻って取得しています唯一のものは、アプリケーション名を持つ構造体である - 。ROOTPATH、マッピングまたはcustomTagPathのような他の変数がない
ここで私がApplication.cfcの中に持っているものです
<cfcomponent output="false">
<cfset this.name = left("App_#hash(getCurrentTemplatePath())#",64)>
<cfset this.applicationTimeout = createTimeSpan(0,8,0,0)>
<cfset this.sessionManagement=True>
<cfset this.loginStorage = "session">
<cfset this.clientManagement = False>
<cfset this.setClientCookies = True>
<cfset this.setDomainCookies = False>
<cfset this.scriptProtect = "all">
<cfset this.rootPath = getDirectoryFromPath(getCurrentTemplatePath())>
<cfset this.mappings = this.rootPath>
<cfset this.customTagPaths = "#this.rootPath#Components">
解決
これらの設定は、アプリケーションスコープに含まれていないので、
です。あなたは、アプリケーションの値に対してアプリケーションをの設定の混乱しています。あなたは、アプリケーションのスコープ内にそれらが利用可能にしたい場合、あなたは単にあなたのonApplicationStartでそれらを設定することができます()。あなたはもちろんのこの範囲を経由してそれらを見ることができるので、あなたはそこに値をコピーします。
所属していません StackOverflow