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.

User Experience Tabbing

  1. On my new form, when the user enters the first field and tabs, the field she goes to is not in the form but rather the first field in the next form. (At the moment, I'm trying out repeating the form "below the fold".) Before I added the second form tabbing put the user into the comments box. I've noticed this on other forms. How can I change this behavior so that a tab takes the user to the next field in the form?

    Thanks
    To see go to: http://www.sharinghousing.com/i-need-help-now

    Posted 12 years ago on Friday January 13, 2012 | Permalink
  2. It sounds like you just need to set the tabindex for the forms. You can find more info on that here:

    http://www.gravityhelp.com/documentation/page/Embedding_A_Form

    Depending on how you are placing the forms - setting that can vary, but you should be able to get through it. Let me know if you get stuck.

    Posted 12 years ago on Friday January 13, 2012 | Permalink
  3. So if I'm understanding right, I can add this piece of code to my "custom_functions.php" file? (Im using Thesis.)

    '<?php gravity_form($tabindex); ?>'

    Posted 12 years ago on Friday January 13, 2012 | Permalink
  4. kyle
    Member

    With what you have, the $tabindex would refer to the form ID. You need all the arguments in your call:

    <?php
    
    $form_id = 1;
    $display_title = true;
    $display_description = true;
    $display_inactive = false;
    $field_values = null;
    $ajax = false;
    $tabindex = 20;
    
    gravity_form($form_id, $display_title, $display_description, $display_inactive, $field_values, $ajax, $tabindex); 
    
    ?>
    Posted 12 years ago on Friday January 13, 2012 | Permalink
  5. I'm a little stuck because it's requiring more PHP than I know. I'm willing to learn but I think asking directly for help will be fastest.

    Here's what I "get"

    This is the sample code. 'lt;?php gravity_form($id, $display_title=true, $display_description=true, $display_inactive=false, $field_values=null, $ajax=false, $tabindex); ?>

    I only need this much '<?php gravity_form($tabindex); ?>'; but I'm not sure how to include it on my site.

    I'm using Thesis so I have a PHP file called "custom_functions.php" SInce the <?php declaration is at the beginning of the file. I don't need that part, right?

    So is it as simple as adding this line into the file?
    function gravity_form($tabindex);

    Or could I put this '<?php gravity_form($tabindex); ?>' into the page? This I should use the custom_functions file?

    Thanks for clarifying. And educating me if I misunderstood.
    I know enough that I don't want to guess!

    See what Thesis has done to me? I guess what I'm asking is the grammar for PHP.

    Thanks,

    Posted 12 years ago on Friday January 13, 2012 | Permalink
  6. Well for anyone who is reading this thread... the best answer was NOT to have two forms on a page and to turn off comments so that there is only one form on the page. Then things work just fine. Thanks anyway for your help.

    Posted 12 years ago on Saturday January 14, 2012 | Permalink
  7. Turning off the comment form is a good idea when there is another form on the page.

    If you'd like help setting the tabindex for one of your forms, please post again and we will help you with that. It's possible to have more than one form on a page, but Gravity Forms does not know that, so it numbers the tabindexes exclusively and individually. That means there are fields in different forms with the same tabindex, which makes for a bad user experience.

    We can help you with straightening it out. It's possible to have multiple forms on one page and have the tabbing work as expected.

    Posted 12 years ago on Saturday January 14, 2012 | Permalink
  8. I appreciate it. At some point, I'll dig into understanding the PHP and where it should go. For now, I've solved my problem - and i think it's actually a better solution.
    Thanks,

    Posted 12 years ago on Saturday January 14, 2012 | Permalink
  9. kyle
    Member

    Maybe you don't need to use PHP. How are you calling your form? If you're using a shortcode when editing your page, like this:

    [gravityform form=1]

    then you'd just need to add the tabindex starting number:

    [gravityform form=1 tabindex=32]

    where 32 would be the starting tabindex.

    Posted 12 years ago on Monday January 16, 2012 | Permalink