devxlogo

Make an Image Act as a Submit Button

Make an Image Act as a Submit Button

Question:

I’m trying to make a small image at the bottom of each form submit information from my database to the user when the user presses on it. However, I don’t want to use an actual submit button because it is too big?it needs to be a small image that acts as a submit button. How can I make an image act like a submit button for a form?

Answer:

You know how to make a regular submit button:

This code will provide a standard command button with the caption, “Click Me”. When the user clicks on it, the form will be submitted.

To replace the button with an image, use this code:

This code will make your image act as a submit button. Clicking on the image will submit the form. By default, Netscape will place a border around the image. If you do not want a border, then add the attribute BORDER=”0″ to the tag.

See also  Why ChatGPT Is So Important Today
devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist