images like buttons

They have: 40 posts

Joined: Jul 2001

I am using this script:

<script>
function getit() {
if (document.former.IDS.value == "id1") {location.replace('http://altavista.com')}
else if (document.former.IDS.value == "id2"){location.replace('http://northernlight.com')}
else {alert("That username is not on the list")}

}
</script>

And wish to use an image instead of the button. Any suggestions? Thanks!

Jack Michaelson's picture

He has: 1,733 posts

Joined: Dec 1999

replace:

with:

you can also use OnMouseDown/Up/Over/Out in stead of OnClick.

Hope it helps,

They have: 40 posts

Joined: Jul 2001

Looks good... Thanks!

They have: 40 posts

Joined: Jul 2001

Of course now that we have gotten that script to work - they want it changed. So here is the new scenario -

There is going to be three radio buttons and two text fields. What needs to happen is that someone must check a radio button and put in a range of dates into the text fields. The first field being the oldest date and the second field being the newest one. When they click on that go button, a page is going to show up depending on what radio button was clicked and what dates were put in.... how is this done?!

Thanks for your help - it is really appreciated!

detox's picture

They have: 571 posts

Joined: Feb 2001

all you need do is check the values returned, this is easiest in ASP or some server side scripting environment. The other thing you can do is set up a dynamic updateable form, whereby the contents of the form are changed depending on the input. Will hunt down the secondary and re-post.

They have: 40 posts

Joined: Jul 2001

Thanks detox - I'd appreciate it if you could do that....

Want to join the discussion? Create an account or log in if you already have one. Joining is fast, free and painless! We’ll even whisk you back here when you’ve finished.