Ask a Question related to Macromedia ColdFusion, Design and Development.

  1. #1

    Default nesting output

    I have a form with dynamically created fields -- something like:
    name=status-#mem_id#

    When I submit this form data to the template that processes it, I want to be
    able to loop through the same query that created the form fields and refer to
    the form field -- something like #FORM.status#QUERY.mem_id##. That of course
    doesn't work. But I also tried
    <CFOUTPUT>#FORM.status<CFOUTPUT>#query.mem_id#</CFOUTPUT>#</CFOUTPUT> and that
    didn't work either.

    I realize I could do something trickier using an array or two but was hoping
    there would be a simpler way to just pop the value into the FORM variable.

    Any ideas?

    Ellie

    choirellie Guest

  2. Similar Questions and Discussions

    1. Nesting floating <div>
      is their a way to contain floating <div>? or an alternative solution? For example; if I wanted to create a 750pixels wide site centred in the...
    2. Nesting connections
      I just installed 3.1 and one of the options is nested connections, I am not sure if I quite understand it so thought I would check the general...
    3. Nesting Component within MC
      Hi, I have a movie where I am nested within two MC's ie first MC > second MC > Im here! I want to place a list component and xml connector within...
    4. Nesting & Grouping
      Sorry if this appears a little basic, but could someone explain to me the difference between nesting and grouping objects? (if there is one). If...
    5. Nesting
      It can be done, I know I have seen it, but for the heck I can't remember. Nesting the substitute function within a script. Here's what I have....
  3. #2

    Default Re: nesting output

    Have you tried useing the CF Function Evaluate. I think it would be writen
    something like this... <cfset var=Evaluate('FORM.status.#QUERY.mem_id#]')> or
    #Evaluate(FORM.status(QUERY.mem_id))# I think thats pretty close I may have
    missed a dot or two... I'm alittle syntaxcally-tarded but check out
    [url]http://livedocs.macromedia.com/coldfusion/7/htmldocs/wwhelp/wwhimpl/common/html/[/url]
    wwhelp.htm?context=ColdFusion_Documentation&amp;fi le=00000945.htm

    Knum Guest

  4. #3

    Default Re: nesting output

    Aha! Yes, using the eval function with a CFSET tag did the trick! Thanks! Your syntax was fine except for the square bracket which I think isn't needed.

    Ellie
    choirellie Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139