- This topic is empty.
March 4, 2016 at 12:16 am #238650
Hello- I’m using Contact Form 7 on wordpress and am having an issue with tabindex not working. Apparently I’m formatting something incorrectly. Tried to resolve on the plugin support forum but I’m not getting anywhere. Hoping someone has an idea on how to resolve this.
[text* tabindex:1 placeholder "Name *"] [email* tabindex:2 placeholder "Email *"] [text tabindex:3 placeholder "Subject"] [textarea* tabindex:4 placeholder "Your message *"] [submit "Send Message"]March 7, 2016 at 1:55 pm #238812
This really shouldn’t be an issue, no? Form elements are focusable in the browser natively and don’t require a tabindex. You should just be able to remove those and have it work as intended.
Unless there’s some other issue at hand?March 7, 2016 at 4:50 pm #238822
I tried without tagindex and it doesn’t work either.March 7, 2016 at 4:55 pm #238823
Do you have a link? Or perhaps make a reduced test with a CodePen?March 7, 2016 at 5:00 pm #238824
Here is a small demo, you can tab to input fields just fine without a tabindex. http://codepen.io/jason-kinney/full/XdXPaV/
Unless I’m misunderstanding what you’re trying to accomplish?March 7, 2016 at 5:05 pm #238825
OK- I need to clarify. I want to have the cursor in the first form field when the page loads so the user doesn’t have to click.March 7, 2016 at 5:13 pm #238826
Ah, thank you for clarifying. If that’s the case, then tabindex is not what you want. If you apply autofocus to the first input, that should give you what you’re looking for…
<input type="text" id="name" autofocus/>
- The forum ‘CSS’ is closed to new topics and replies.