Title:
Bug 72305:(Watson Migration Closure)application specific default values for tag attributes
| View in TrackerStatus/Resolution/Reason: Closed/Deferred/
Reporter/Name(from Bugbase): Jochem van Dieten / Jochem van Dieten (Jochem van Dieten)
Created: 07/11/2008
Components: Language
Versions: 9.0
Failure Type: Unspecified
Found In Build/Fixed In Build: 0000 /
Priority/Frequency: Normal / Unknown
Locale/System: English / Platforms All
Vote Count: 3
Problem:
application specific default values for tag attributes
In various forums we have over the last year discussed the possibility
of default values for tag attributes, but AFAIK there has never been a
conclusion / design. So I would like to kick off a new discussion with a
design of how I would like to have this feature implemented.
Default values should:
- be application specific;
- be defined in Application.cfc;
- override configuration options in the CF Administrator;
- be overridden by the attributesCollection of the tag;
- be overridden by the attributes of the tag.
In terms of syntax I think defining the default values should look
something like this:
Application.cfc:
<cfcomponent>
<cfset this.name = "exampleApp" />
<cfset this.tagdefaults.cfmail.server = "192.168.17.1" />
<cfset this.tagdefaults.cfmail.port = 587 />
<cfset this.tagdefaults.cfquery.datasource = "dsn_example" />
<cfset this.tagdefaults.cffunction.output = FALSE />
<cfset ....
Then in your code you could start to use code like:
<cfquery name="expiredUsers">
SELECT ...
<cfquery>
and CF would automatically add the datasource attribute from the
tagdefaults.
Discussion in the prerelease forums was at https://prerelease.adobe.com/project/forum/thread.html?cap=87529BDA13744B3DB718E841890B9240&forid={267A8BEA-8D25-435C-A533-6C830DD686CA}&topid={4F96D02B-4AA4-42CC-A41E-5791990D6944}
Method:
Result:
----------------------------- Additional Watson Details -----------------------------
Watson Bug ID: 3035486
External Customer Info:
External Company:
External Customer Name: Jochem van Dieten
External Customer Email: 14B70C2D446042B59920157F
External Test Config: 07/11/2008
Attachments:
Comments: