PLEASE NOTE: These forums are no longer utilized and are provided as an archive for informational purposes only. All support issues will be handled via email using our support ticket system. For more detailed information on this change, please see this blog post.

All "CAPS" to complete the form.

  1. zx7md
    Member

    How can I make to every single field to be populated with "caps" and not lower cases.

    If the client put his name, last name etc, all the information will change to CAPS. or on the email the form send to me all the values will be in caps. Whatever is the easiest to do, please let me know how.

    Thanks!

    Posted 12 years ago on Tuesday October 16, 2012 | Permalink
  2. David Peralty

    Can you explain a bit more about why you would want to do this? As far as I know, it would have to be done on a field by field basis through some PHP.

    Posted 12 years ago on Tuesday October 16, 2012 | Permalink
  3. zx7md
    Member

    My costumer asked me to do that because they think it will be easier to read all in caps.
    Could you please help me out?

    Posted 12 years ago on Tuesday October 16, 2012 | Permalink
  4. You can do this with CSS on the front-end, which will be more of just a visual representation, not "actually" in caps. But if this is more for a back-end/admin purpose, and not for the user - then my suggestion is moot.

    Posted 12 years ago on Tuesday October 16, 2012 | Permalink
  5. zx7md
    Member

    The email that form sends, i need the results from each fields been in caps. How can I make it happens? "CSS on the front-end" ? Please let me know

    Posted 12 years ago on Tuesday October 16, 2012 | Permalink
  6. You could use the gform_pre_submission filter http://www.gravityhelp.com/documentation/page/Gform_pre_submission to modify the submitted values, changing them to CAPS, then storing that. That value would be used in the notifications as well. Your code would look something like this:

    [php]
    // we can add a form ID here if we need to
    add_filter('gform_pre_submission', 'uppercase_me');
    function uppercase_me($form) {
        // this will change the values in 3 specific fields to UPPERCASE
        $_POST['input_14'] = strtoupper($_POST['input_14']);
        $_POST['input_10'] = strtoupper($_POST['input_10']);
        $_POST['input_25'] = strtoupper($_POST['input_25']);
    }

    You can loop through all the $_POST values or you can change just the ones you really want uppercased.

    Posted 12 years ago on Tuesday October 16, 2012 | Permalink
  7. zx7md
    Member

    Ok, I'll try and let you know.

    Thank you so much for the support!!!

    Posted 12 years ago on Friday October 19, 2012 | Permalink
  8. If input_14 is the name field in normal format or the address field, this function doesn't transform the individual fields. I tried input_14.3 and input_14.6 with no luck.

    Posted 11 years ago on Tuesday June 11, 2013 | Permalink
  9. David Peralty

    Try input_14_3 and input_14_6.

    Posted 11 years ago on Tuesday June 11, 2013 | Permalink
  10. Thank you, that worked!

    Posted 11 years ago on Wednesday June 12, 2013 | Permalink