Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Accessible HTML Form input types - "submit" vs "image"

Tags:

html

css

forms

Is there any real difference to screen reader users (or any users really) whether i use "image" rather than "submit" as the type attribute for my form submission button?

eg:

<input type="submit" value="Submit!" />

vs

<input type="image" src="myButtonImage.jpg" value="Submit!" alt="Submit!" />
like image 430
Ben Avatar asked May 15 '09 03:05

Ben


People also ask

What type of input tag is better is it type button or type submit?

<button> is newer than <input type="submit"> , is more semantic, easy to stylize and support HTML inside of it.

What is the difference between input type submit and button in HTML?

Difference between <button type="submit"> and <input type="submit"> Both <button type="submit"> and <input type="submit"> display as buttons and cause the form data to be submitted to the server. The difference is that <button> can have content, whereas <input> cannot (it is a null element).

What is the difference between input fields submit and button?

A 'button' is just that, a button, to which you can add additional functionality using Javascript. A 'submit' input type has the default functionality of submitting the form it's placed in (though, of course, you can still add additional functionality using Javascript).


1 Answers

Nope, they're essentially the same.

See: Using 'button' and images for submit. Just make sure to always give the image submit alt text.

like image 68
thedz Avatar answered Sep 29 '22 06:09

thedz