Answers.Body: <p>You need to pass your custom fields in a <code>fields</code> array, try:</p>
  <pre><code>{{ input('text', 'fields[headline]', entry.headline, {
      required: true,
      class: entry.hasErrors('headline') ? 'text error' : 'text'
  }) }}
  </code></pre>
  <p>See example here - <a href="https://craftcms.com/knowledge-base/entry-form" rel="nofollow noreferrer">https://craftcms.com/knowledge-base/entry-form</a></p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-11-10T15:03:42.060Z
Answers.Text: Thanks so much Oli, that's what I needed. It's my first time making an Entry Form. The [Entry Form doc](https://craftcms.com/docs/3.x/dev/examples/entry-form.html) really ought to make this point but it doesn't!
Answers.UserDisplayName: Jonathan Schofield
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-11-10T15:07:53.190Z
Answers.Text: Just talking with Matt about it so we make it more obvious :) Glad you're sorted!
Answers.UserDisplayName: Oli
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-11-10T15:13:26.830Z
Answers.Text: Ironically all my most complex fields already had `fields[handle]` going on, but the simplest ones didn't because they were derived from the root doc!
Answers.UserDisplayName: Jonathan Schofield
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-11-10T14:55:36.960Z
Answers.LastActivityDate: 2020-11-10T15:05:56.847Z
Answers.LastEditDate: 2020-11-10T15:05:56.847Z
Answers.UserDisplayName: Oli
Body: <p>I have an entry form (in a local v3.5.13.1 dev context) configured to update existing entries in a particular section. On load, it’s reflecting existing data (input via the Craft control panel) perfectly well, including Assets and Matrix field content.</p>
  <p>But when I'm logged in as a <strong>Super Admin</strong> and I submit changes, it will receive updates to the entry <code>Title</code> field but not to any custom fields.</p>
  <p>No errors are being reported and it redirects to the desired page.</p>
  <p>At present, I have stripped it right back to the <code>Title</code> field and a single Plain Text custom field but no joy. Here is my form code:</p>
  <pre><code>{% set entry = entry ?? create('craft\\elements\\Entry') %}
  {% set redirectUrl = &quot;partners/#{entry.id}&quot; %}
  {% set sectionId = entry.sectionId %}
  
  &lt;form method=&quot;post&quot; accept-charset=&quot;UTF-8&quot;&gt;
      {{ csrfInput() }}
      {{ actionInput('entries/save-entry') }}
      {{ redirectInput(redirectUrl) }}
      {{ hiddenInput('sectionId', '5') }}
      {{ hiddenInput('enabled', '1') }}
      {{ hiddenInput('entryId', entry.id) }}
      {{ hiddenInput('entryVariable', 'badEntry'|hash) }}
  
      {% macro errorList(errors) %}
          {% if errors %}
          &lt;ul class=&quot;errors&quot;&gt;
              {% for error in errors %}
                  &lt;li&gt;{{ error }}&lt;/li&gt;
              {% endfor %}
          &lt;/ul&gt;
          {% endif %}
      {% endmacro %}
            
      &lt;p&gt;
          &lt;label class=&quot;field-below&quot;&gt;
              &lt;span class=&quot;field-label&quot;&gt;&lt;strong&gt;Organisation name&lt;/strong&gt;&lt;/span&gt;
              {{ input('text', 'title', entry.title, {
                  required: true,
                  class: entry.hasErrors('title') ? 'text error' : 'text'
              }) }}
              {{ _self.errorList(entry.getErrors('title')) }}
          &lt;/label&gt; 
      &lt;/p&gt;
  
      &lt;p&gt;
          &lt;label class=&quot;field-below&quot;&gt;
              &lt;span class=&quot;field-label&quot;&gt;
                  &lt;strong&gt;Headline:&lt;/strong&gt;
                  &lt;span class=&quot;line-ib&quot;&gt;Optional, 10 words or fewer recommended&lt;/span&gt;
              &lt;/span&gt; 
              {{ input('text', 'headline', entry.headline, {
                  required: true,
                  class: entry.hasErrors('headline') ? 'text error' : 'text'
              }) }}
              {{ _self.errorList(entry.getErrors('headline')) }}
          &lt;/label&gt; 
      &lt;/p&gt;
  
      &lt;p class=&quot;field-submit&quot;&gt;
          &lt;input type=&quot;submit&quot; class=&quot;btn&quot; value=&quot;Update page&quot;&gt;
      &lt;/p&gt;
  &lt;/form&gt;
  </code></pre>
  <p>No updates to the <code>Headline</code> field get saved. Updates to the <code>Title</code> field do. Where can I be going wrong?</p>
  
Tags: <entry-form>
Title: Front-end entry form not updating custom fields in existing entry
ThreadText: # Front-end entry form not updating custom fields in existing entry
  
  (Asked by: username_0 on 2020-11-10)
  
  I have an entry form (in a local v3.5.13.1 dev context) configured to update existing entries in a particular section. On load, it’s reflecting existing data (input via the Craft control panel) perfectly well, including Assets and Matrix field content.
  
  But when I'm logged in as a **Super Admin** and I submit changes, it will receive updates to the entry `Title` field but not to any custom fields.
  
  No errors are being reported and it redirects to the desired page.
  
  At present, I have stripped it right back to the `Title` field and a single Plain Text custom field but no joy. Here is my form code:
  
  ```
  {% set entry = entry ?? create('craft\\elements\\Entry') %}
  {% set redirectUrl = "partners/#{entry.id}" %}
  {% set sectionId = entry.sectionId %}
  
  <form method="post" accept-charset="UTF-8">
      {{ csrfInput() }}
      {{ actionInput('entries/save-entry') }}
      {{ redirectInput(redirectUrl) }}
      {{ hiddenInput('sectionId', '5') }}
      {{ hiddenInput('enabled', '1') }}
      {{ hiddenInput('entryId', entry.id) }}
      {{ hiddenInput('entryVariable', 'badEntry'|hash) }}
  
      {% macro errorList(errors) %}
          {% if errors %}
          <ul class="errors">
              {% for error in errors %}
                  <li>{{ error }}</li>
              {% endfor %}
          </ul>
          {% endif %}
      {% endmacro %}
            
      <p>
          <label class="field-below">
              <span class="field-label"><strong>Organisation name</strong></span>
              {{ input('text', 'title', entry.title, {
                  required: true,
                  class: entry.hasErrors('title') ? 'text error' : 'text'
              }) }}
              {{ _self.errorList(entry.getErrors('title')) }}
          </label> 
      </p>
  
      <p>
          <label class="field-below">
              <span class="field-label">
                  <strong>Headline:</strong>
                  <span class="line-ib">Optional, 10 words or fewer recommended</span>
              </span> 
              {{ input('text', 'headline', entry.headline, {
                  required: true,
                  class: entry.hasErrors('headline') ? 'text error' : 'text'
              }) }}
              {{ _self.errorList(entry.getErrors('headline')) }}
          </label> 
      </p>
  
      <p class="field-submit">
          <input type="submit" class="btn" value="Update page">
      </p>
  </form>
  
  ```
  
  No updates to the `Headline` field get saved. Updates to the `Title` field do. Where can I be going wrong?
  
  **Tags:** entry-form
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2020-11-10. Score: 3 | Accepted answer
  
  You need to pass your custom fields in a `fields` array, try:
  
  ```
  {{ input('text', 'fields[headline]', entry.headline, {
      required: true,
      class: entry.hasErrors('headline') ? 'text error' : 'text'
  }) }}
  
  ```
  
  See example here - <https://craftcms.com/knowledge-base/entry-form>
  
  > **Comments:**
  > **username_0**: Thanks so much Oli, that's what I needed. It's my first time making an Entry Form. The [Entry Form doc](https://craftcms.com/docs/3.x/dev/examples/entry-form.html) really ought to make this point but it doesn't!  
  > **username_1**: Just talking with Matt about it so we make it more obvious :) Glad you're sorted!  
  > **username_0**: Ironically all my most complex fields already had `fields[handle]` going on, but the simplest ones didn't because they were derived from the root doc!  
  
  ---
  
  