Answers.Body: <p>There's not an "elegant" way to do this but you can access the dropdown field by its handle using <code>getFieldByHandle</code>. Something like:</p>
  
  <pre><code>{% set dropdownField = craft.fields.getFieldbyHandle('isotope') %}
  
    {% for option in dropdownField.settings.options %}
      &lt;li&gt;{{ option.value }}&lt;/li&gt;
    {% endfor %}
  </code></pre>
  
  <p>If you need the label instead, just use <code>{{ option.label }}</code></p>
  
  <p>You can also grab a dropdown's options from any entry you know has the field already attached, such as the first entry from your <code>news</code> section for example:</p>
  
  <pre><code>{% set entry = craft.entries.section('news').limit(1)[0] %}
  
  &lt;ul&gt;
  {% for option in  entry.isotope.options %}
      &lt;li&gt;{{ option.value }}&lt;/li&gt;
  {% endfor %}
  &lt;/ul&gt;
  </code></pre>
  
  <p>Note: similar to <a href="https://craftcms.stackexchange.com/questions/2205/how-do-i-output-a-dropdowns-values-if-im-on-a-registration-form-not-tied-to-an">this</a> question.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-07T00:59:33.493Z
Answers.Text: Your first approach is just what I needed to print the field options into the isotope data-filter.  Thanks.
Answers.UserDisplayName: Hellyar
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-02-07T00:22:52.157Z
Answers.LastActivityDate: 2017-02-07T00:31:54.123Z
Answers.LastEditDate: 2017-04-13T12:51:00.303Z
Answers.UserDisplayName: RitterKnight
Body: <p>I have a dropdown field with X options.  I want to print each option as a button.</p>
  
  <p>I tried...</p>
  
  <pre><code>&lt;ul&gt;
      {% for option in entry.isotope.options %}
          &lt;li&gt;{{ option }}&lt;/li&gt;
      {% endfor %}
  &lt;/ul&gt;
  </code></pre>
  
  <p>isotope = dropdownFieldHandle</p>
  
  <p>But I get the error <code>Variable "entry" does not work'</code>.</p>
  
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-06T23:30:16.157Z
Comments.Text: Are you actually trying to call this in an ``entry`` template? ``entry`` won't [automatically](https://craftcms.com/docs/routing) get created by Craft if you're on a ``category`` or custom route, for example.
Comments.UserDisplayName: RitterKnight
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-06T23:38:34.713Z
Comments.Text: No, I am not in the entry template.  I tried  using set to entry in craft.entries.section('posts'), but that just printed out the title of all the entries instead of the handful of options in the dropdown field.
Comments.UserDisplayName: Hellyar
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-07T00:00:27.087Z
Comments.Text: That's your problem. Which post are you actually trying to get? When you call ``craft.entries`` you're going to get a group of entries back based on the parameters you specify. You might try something like ``{% set entry = craft.entries.section('posts').slug('post-with-isotope-options')[0] %}`` to get just one entry.
Comments.UserDisplayName: RitterKnight
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-07T00:02:14.090Z
Comments.Text: But I don't want the entries.  I just want to print the options in the field dropdown.
Comments.UserDisplayName: Hellyar
Comments.ContentLicense: CC BY-SA 3.0
Comments.CreationDate: 2017-02-07T00:35:42.347Z
Comments.Text: Gotcha, couple ways to do that, see answer below.
Comments.UserDisplayName: RitterKnight
Tags: <templating>
Title: How do I print the options in a dropdown field?
ThreadText: # How do I print the options in a dropdown field?
  
  (Asked by: username_0 on 2017-02-06)
  
  I have a dropdown field with X options. I want to print each option as a button.
  
  I tried...
  
  ```
  <ul>
      {% for option in entry.isotope.options %}
          <li>{{ option }}</li>
      {% endfor %}
  </ul>
  
  ```
  
  isotope = dropdownFieldHandle
  
  But I get the error `Variable "entry" does not work'`.
  
  **Tags:** templating
  
  > **Comments:**
  > **username_1**: Are you actually trying to call this in an ``entry`` template? ``entry`` won't [automatically](https://craftcms.com/docs/routing) get created by Craft if you're on a ``category`` or custom route, for example.  
  > **username_0**: No, I am not in the entry template.  I tried  using set to entry in craft.entries.section('posts'), but that just printed out the title of all the entries instead of the handful of options in the dropdown field.  
  > **username_1**: That's your problem. Which post are you actually trying to get? When you call ``craft.entries`` you're going to get a group of entries back based on the parameters you specify. You might try something like ``{% set entry = craft.entries.section('posts').slug('post-with-isotope-options')[0] %}`` to get just one entry.  
  > **username_0**: But I don't want the entries.  I just want to print the options in the field dropdown.  
  > **username_1**: Gotcha, couple ways to do that, see answer below.  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2017-02-07. Score: 5 | Accepted answer
  
  There's not an "elegant" way to do this but you can access the dropdown field by its handle using `getFieldByHandle`. Something like:
  
  ```
  {% set dropdownField = craft.fields.getFieldbyHandle('isotope') %}
  
    {% for option in dropdownField.settings.options %}
      <li>{{ option.value }}</li>
    {% endfor %}
  
  ```
  
  If you need the label instead, just use `{{ option.label }}`
  
  You can also grab a dropdown's options from any entry you know has the field already attached, such as the first entry from your `news` section for example:
  
  ```
  {% set entry = craft.entries.section('news').limit(1)[0] %}
  
  <ul>
  {% for option in  entry.isotope.options %}
      <li>{{ option.value }}</li>
  {% endfor %}
  </ul>
  
  ```
  
  Note: similar to [this](https://craftcms.stackexchange.com/questions/2205/how-do-i-output-a-dropdowns-values-if-im-on-a-registration-form-not-tied-to-an) question.
  
  > **Comments:**
  > **username_0**: Your first approach is just what I needed to print the field options into the isotope data-filter.  Thanks.  
  
  ---
  
  