1
我想爲FW/1創造一個輕量級的腳手架設施。現在我有看起來像重量輕的腳手架FW/1
<cfcomponent hint="this is expected to be extended, and never used directly">
<cfscript>
function init(fw) { variables.fw = fw; }
void function home (required struct rc) output="false" {
/* TODO: Generic load */
setView("scaffold.home");
}
void function create (required struct rc) output="false" {
/* TODO: Generic create */
setView("scaffold.create");
}
void function show (required struct rc) output="false" {
/* TODO: Generic show */
setView("scaffold.show");
}
...
</cfscript>
</cfcomponent>
我想確保index.cfm?action=scaffold.*
或index.cfm/scaffold/*
不能跑控制器名爲scaffold.cfc
文件。
最好的地方在哪裏?