You need to make a slight change:

instead of looping the number of items in the list, why not loop through the
list itself?

<cfloop list="#thelist#" index="i">
        <cfoutput>
        <a
href="http://www.domain.com/search_children.cfm?parent=#i#";>#i#</a>
         </cfouput>
</cfloop>

-------------------------------------------------------
Rich Wild
Senior Web Designer

-------------------------------------------------------
e-mango.com ltd                      Tel: 01202 587 400
Lansdowne Place                      Fax: 01202 587 401
17 Holdenhurst Road
Bournemouth                   Mailto:[EMAIL PROTECTED]
BH8 8EW, UK                      http://www.e-mango.com
-------------------------------------------------------
This message may contain information which is legally
privileged and/or confidential.  If you are not the
intended recipient, you are hereby notified that any
unauthorised disclosure, copying, distribution or use
of this information is strictly prohibited. Such
notification notwithstanding, any comments, opinions,
information or conclusions expressed in this message
are those of the originator, not of e-mango.com ltd,
unless otherwise explicitly and independently indicated
by an authorised representative of e-mango.com ltd.
-------------------------------------------------------




> -----Original Message-----
> From: L Williams [mailto:[EMAIL PROTECTED]]
> Sent: 27 April 2001 16:53
> To: CF-Talk
> Subject: Re: List Functions
> 
> 
> Hi Robert,
> Thanks for the tip, but it didn't work.
> The server can't figure out what theLoop is
> 
> I get :
> Error Occurred While
> Processing Request
> Error Diagnostic Information
> An error occurred while evaluating the expression:
> #listgetat(theloop,i)#
> Error near line 42, column 95.
> Error resolving parameter  THELOOP
> ColdFusion was unable to determine the value of the 
> parameter. This problem is very likely
> due to the fact that either:
>  -You have misspelled the parameter name, or
>  -You have not specified a QUERY attribute
> for a CFOUTPUT, CFMAIL, or CFTABLE tag.
> The error occurred while processing an element with a general 
> identifier of
> (#listgetat(theloop,i)#), occupying document position (42:94) to
> (42:115) in the template file
> /opt/coldfusion/CustomTags/bestbets/rTreelw.cfm
> 
> Any clues?
> 
> Thanks in advance - I'm still stumped.
> Loryn
> 
> 
> 
> Robert Segal wrote:
> 
> > Try something like this:
> >
> > <cfloop from="1" to = "#listlen(thelist)#" index="i">
> >         <cfoutput>
> >                 <a
> > 
> href="http://www.domain.com/search_children.cfm?parent=#listge
> tat(theloop,i)
> > #">#listgetat(theloop,i)#</a>
> >         </cfouput>
> > </cfloop>
> >
> > Assuming your list is in a variable called thelist (e.g. thelist =
> > "Corporate Life,Amenities,Cafeteria")
> >
> > -----Original Message-----
> > From: Loryn C Williams [mailto:[EMAIL PROTECTED]]
> > Sent: Friday, April 27, 2001 6:47 AM
> > To: CF-Talk
> > Subject: List Functions
> >
> > All,
> > I think I have a fairly simple problem, but I can't for the 
> life of me
> > figure out how to get this done.
> >
> > I have a custom tag that traverses up a tree and produces a 
> list (good)
> > How do I make each list item (as it is output) contain a 
> url reference
> > and values to call another
> > cf custom tag?
> >
> > For example my list produces
> >
> > Corporate Life - Amenities - Cafeteria
> >
> > I would like it to say
> > <a href="http://www.domain.com/search_children.cfm?parent=Corporate
> > Life>Corporate Life </a> etc..
> >
> > I have not had any luck at all with this and any help would 
> be GREATLY
> > appreciated.
> > Thank You in advance
> > Loryn Williams
> >
> >
>
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
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

Reply via email to