ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Quick question about Safecracker and required fields

July 23, 2012 2:04pm

Subscribe [1]
  • #1 / Jul 23, 2012 2:04pm

    gaarmaster

    39 posts

    Hello,

    I currently have a Safecracker form on my site and a couple of required fields included. I’ve noticed that sometimes the values entered in other fields disappear on submit if there is an error in the form (like a required field that hasn’t been filled in). Is there a simple way to keep the values populated on submit?

    I am currently using code provided by the user guide:

    <input type="text" name="my_field_name" id="my_field_name" value="{my_field_name}">

    Any help would be appreciated.

    Thanks!

  • #2 / Jul 24, 2012 12:56pm

    Kevin Smith

    4784 posts

    Hi gaarmaster,

    Are you using {my_field_name} in the value parameters of all your fields? Is the behavior consistent or does it change every time it happens (always the same fields that blank)? Have you been able to nail down any specific pattern?

    Could you post your template code back here for review?

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases