Am I right in thinking that you could also
assign the query to the request scope in the calling
page and reference it that way in the tag?
Just a thought
Tristram Charnley
-----------------
[EMAIL PROTECTED]
"If something is hard to do, its not worth doing!"
Homer Simpson.
> -----Original Message-----
> From: Brad Roberts [mailto:[EMAIL PROTECTED]]
> Sent: 15 March 2001 02:49
> To: CF-Talk
> Subject: RE: Custom Tag
>
>
> Wouldn't it work to pass "caller.myquery" to the tag?
>
> <cf_mytag queryname="caller.myquery">
>
> ----mytag.cfm----
>
> <cfloop query="#attributes.queryname#">
> blah
> </cfloop>
>
>
>
> > -----Original Message-----
> > From: Jason Aden [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, March 14, 2001 9:27 PM
> > To: CF-Talk
> > Subject: RE: Custom Tag
> >
> >
> > Scott,
> >
> > I don't think accessing #attributes.query_name# will work
> in your example
> > because that variable just holds the text string name of the query.
> >
> > You could however pass the whole query to the custom tag like:
> >
> > <cfquery name="xxx" datasource="qry_y">
> > select a,b,c
> > from y
> > </cfquery>
> >
> > <cf_MyTag query="#xxx#">
> >
> > And then access the query within the custom tag as:
> >
> > <cfloop query="attributes.xxx">
> > actions...
> > </cfloop>
> >
> > HTH,
> >
> > Jason
> >
> > ----
> > Jason Aden
> > Allaire Certified Developer
> > [EMAIL PROTECTED]
> > www.wwstudios.com
> >
> > > -----Original Message-----
> > > From: Scott, Andrew [mailto:[EMAIL PROTECTED]]
> > > Sent: Wednesday, March 14, 2001 9:01 PM
> > > To: CF-Talk
> > > Subject: RE: Custom Tag
> > >
> > >
> > > And why can't you just use:-
> > >
> > > <cfoutput query="#attributes.query_name#">
> > >
> > > from within the custom tag:-)
> > >
> > >
> > >
> > > -----Original Message-----
> > > From: Toby Tremayne [mailto:[EMAIL PROTECTED]]
> > > Sent: 15 March 2001 12:50
> > > To: CF-Talk
> > > Subject: RE: Custom Tag
> > >
> > >
> > > I pass an attribute to the custom tag : <cf_myTag
> query_name="myQuery">
> > >
> > > and within the custom tag I use:
> > >
> > > <cfoutput query="caller.#attributes.queryname#">
> > >
> > >
> > > it works perfectly
> > >
> > >
> > > Toby Tremayne
> > > Code Poet and Zen Master of the Heavy Sleep
> > > Show Ads Interactive
> > > 359 Plummer St
> > > Port Melbourne
> > > VIC 3207
> > > P +61 3 9245 1247
> > > F +61 3 9646 9814
> > > ICQ UIN 13107913
> > >
> > > -----Original Message-----
> > > From: Nathan Stanford [mailto:[EMAIL PROTECTED]]
> > > Sent: Thursday, 15 March 2001 8:22 AM
> > > To: CF-Talk
> > > Subject: RE: Custom Tag
> > >
> > >
> > > I tried Caller.xxx and it didn't find it I will have to
> test it again...
> > > Maybe I had some other problem... because I thought it would be
> > > that simple
> > > as well.
> > >
> > > Nathan
> > >
> > >
> > >
> > > > -----Original Message-----
> > > > From: Philip Arnold - ASP [SMTP:[EMAIL PROTECTED]]
> > > > Sent: Wednesday, March 14, 2001 11:47 AM
> > > > To: CF-Talk
> > > > Subject: RE: Custom Tag
> > > >
> > > > > When in a custom tag how can you reference the query that is
> > > > > located in the
> > > > > callers page...
> > > > >
> > > > > EX:
> > > > > <cfquery name="xxx" datasource="qry_y">
> > > > > select a,b,c
> > > > > from y
> > > > > </cfquery>
> > > > >
> > > > > <cf_MyTag query="xxx">
> > > > > -----------------------------------
> > > > > MyTag.cfm
> > > > >
> > > > > How can I look at all of the items in the query 'xxx'?
> > > >
> > > > You're going to kick yourself as to how simple this is;
> > > > caller.xxx
> > > >
> > > > Philip Arnold
> > > > Director
> > > > Certified ColdFusion Developer
> > > > ASP Multimedia Limited
> > > > T: +44 (0)20 8680 1133
> > > >
> > > > "Websites for the real world"
> > > >
> > > >
> **********************************************************************
> > > > This email and any files transmitted with it are
> confidential and
> > > > intended solely for the use of the individual or entity
> to whom they
> > > > are addressed. If you have received this email in error
> please notify
> > > > the system manager.
> > > >
> **********************************************************************
> > > >
> > > >
> > > >
> > > >
> > >
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at
http://www.fusionauthority.com/bkinfo.cfm
Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists