Results 1 to 2 of 2

Thread: Tab key skipping a field in a contact form?

  1. #1
    Join Date
    Aug 2006
    Posts
    235
    Thanks
    30
    Thanked 2 Times in 2 Posts

    Default Tab key skipping a field in a contact form?

    Simple thing here, if you got to my site here and you click to leave a comment on any one of my blog posts, then you scroll down and go to my form to leave me a contact, if you use tab to go from Name, to Email and then press it again, it skips over Website, I want it so if you press tab it will go from Name, to Email, to Website and then to the comment field. Here is my comment form:

    Code:
    <p>
    <label><?php _e('Name'); ?> <?php if ($req) _e('(required)'); ?></label>:<br />
    <input type="text" class="input" name="author" id="author" value="<?php echo $comment_author; ?>" size="30" tabindex="1" />
    
    </p>
    
    <p>
    <label><?php _e('E-mail'); ?> <?php if ($req) _e('(required)'); ?></label><br />
    <input type="text" class="input" name="email" id="email" value="<?php echo $comment_author_email; ?>" size="30" tabindex="2" />
    </p>
    
    <p>
    <label>Website</label><br />
    <input type="text" class="input" name="url" id="url" value="<?php echo $comment_author_url; ?>" size="30" tabindex="3" />
    </p>
    ------------------
    Check out my site here and let me know what you think

  2. #2
    Join Date
    Jun 2010
    Posts
    13
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Default

    The textarea below it has tabindex 2, the website field has tabindex 3. You need to change the tabindex for the textarea to 4, and then it will work fine.

    Tim

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •