We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 15083
    • 697 Posts
    Hi there,

    I need to output a TV as a dropdownmenu list.
    I can set it up fine to allow my client to input value==text combos, but is there an easy way to output this TV as a dropdown list?

    Cheers,

    J
      • 28042 ☆ A M B ☆
      • 24,524 Posts
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 15083
        • 697 Posts
        I was kind of hoping I would not have to write my own snippet (because i’m lazy).

        A dropdown Widget would we nice tho? Goes a long way towards making forms etc configurable by the client (Providing they don’t enter rubbish in the TV input and wreck the whole thing)

        Thanks for the help Susan.
          • 15083
          • 697 Posts
          Ran into problems with that approach, let me explain...
          I have a chunk called x that is called from a snippet y. I use parseChunk and then output it from said snippet.

          Within x is the snippet call to handle my dropdowns:
          [[drawdropdown? &selectid=`custom_fontselect_[+form_index+]` &selectname=`custom_fontselect_[+form_index+]`]]

          The placeholder [+form_index+] is generated in snippet y, and replaced.

          Problem: When snippet y runs, it takes the first chunk and process my new snippet call within, but thats it...it just outputs the result and does not loop?
            • 15083
            • 697 Posts
            figured it out...I had pasted over my original snippet...not the first time I have done this mind u!