RE: Can anyone see what's wrong with this cfc method?
Move cfargument above the cfset -Original Message- From: Rick Faircloth [mailto:r...@whitestonemedia.com] Sent: Tuesday, June 01, 2010 5:00 PM To: cf-talk Subject: Can anyone see what's wrong with this cfc method? I'm getting this error: Context validation error for the cffunction tag. The start tag must have a matching end tag. An explicit end tag can be provided by adding /cffunction. ... For this cffunction, and I cannot figure out why: cfcomponent displayName=properties hint=Handles Property Data output=false cffunction name = mGetFeaturedProperty displayName = mGetFeaturedProperty hint = Gets Featured Property output= false returnType= query cfset var qGetFeaturedProperty = / cfargument name = dsn2 type = string required = yes / cfquery name = qGetFeaturedProperty datasource=#arguments.dsn2# selectp.property_id, p.property_type, p.street_number, p.street_name, p.city, p.remarks, p.state, p.rental, pl.propertyPhotoLink, pl.photoLabel, fp.featured_property_id from properties p, hmls_property_photo_links pl, cbhr.featured_properties_cbhr fp where p.mls_number = fp.mls_number and substring_index(p.mls_number, '_', 1) = pl.mlsNumber and pl.photoLabel = 'Main View' group by p.property_id order by rand() limit 1 /cfquery cfreturn qGetFeaturedProperty / /cffunction /cfcomponent ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334203 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Can anyone see what's wrong with this cfc method?
You must put var statements (and other CFML) after any cfargument tag. On Tue, Jun 1, 2010 at 4:00 PM, Rick Faircloth r...@whitestonemedia.com wrote: I'm getting this error: Context validation error for the cffunction tag. The start tag must have a matching end tag. An explicit end tag can be provided by adding /cffunction. ... For this cffunction, and I cannot figure out why: cfcomponent displayName=properties hint=Handles Property Data output=false cffunction name = mGetFeaturedProperty displayName = mGetFeaturedProperty hint = Gets Featured Property output = false returnType = query cfset var qGetFeaturedProperty = / cfargument name = dsn2 type = string required = yes / cfquery name = qGetFeaturedProperty datasource=#arguments.dsn2# select p.property_id, p.property_type, p.street_number, p.street_name, p.city, p.remarks, p.state, p.rental, pl.propertyPhotoLink, pl.photoLabel, fp.featured_property_id from properties p, hmls_property_photo_links pl, cbhr.featured_properties_cbhr fp where p.mls_number = fp.mls_number and substring_index(p.mls_number, '_', 1) = pl.mlsNumber and pl.photoLabel = 'Main View' group by p.property_id order by rand() limit 1 /cfquery cfreturn qGetFeaturedProperty / /cffunction /cfcomponent ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334204 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: Can anyone see what's wrong with this cfc method?
Dang! It's always the simplest things! Thanks, Ray and Bobby! Rick -Original Message- From: Raymond Camden [mailto:rcam...@gmail.com] Sent: Tuesday, June 01, 2010 5:11 PM To: cf-talk Subject: Re: Can anyone see what's wrong with this cfc method? You must put var statements (and other CFML) after any cfargument tag. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology-Michael-Dinowitz/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:334205 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm