[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: image object??

You can use the link and <IMG> tag trick, along with a call to submit the
form.  The tag goes like this:

<A HREF="JavaScript:submitMe()"><IMG SRC=button.gif" ALT="Submit"></A>

Your submitMe function does the sumbitting of the form, and is called when
you click the button.  The function can be as simple as:

function submitMe () {
        document.forms[0].submit();  // submits the first form in the document

The rest of the page -- and the form -- is standard HTML.

-- Gordon

At 11:25 PM 3/8/96 -0800, you wrote:
>is there an image object in javascript? instead of using a submit button in
>a form, it's possible to use a graphic object or image in standard html. in
>going through the javascript documentation, i see all the other form
>objects (checkbox, textarea, radio, etc.), but no image. am i missing
>Bill Berry

For help about the list, please send a message to 'majordomo@obscure.org'
with the message body 'help'. To unsubscribe, send a message to
'majordomo@obscure.org' with the message body 'unsubscribe javascript'.
List archives and pointer to FAQ: http://www.obscure.org/javascript/