Solved

Drop down box and putting an image instead of submit button?

Posted on 2002-07-03
6
155 Views
Last Modified: 2013-12-24
Hello

I have a drop down box with 3 options ,and want put an image instead of submit button so when i click image, a page which is related to (e.g first option )open in another frame,how can i do it?
Thanks
0
Comment
Question by:MOSTAGHASSI
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
6 Comments
 
LVL 19

Accepted Solution

by:
webwoman earned 70 total points
ID: 7127601
You have to edit the code. FrontPage may not help you much.

You need to change it from a SUBMIT to an IMAGE, like this

<input type="image" name="submit" src="yourgraphic.gif" alt="alt text here" width="XXX" height="XXX" border="0">

Naming it SUBMIT causes most browsers to treat it as a submit button.
0
 

Author Comment

by:MOSTAGHASSI
ID: 7127726
hi webwoman

Please let me know how can i relate an option in drop down box to a .html page so when i click image the page open?
0
 

Author Comment

by:MOSTAGHASSI
ID: 7133551
Thank you,but you could write 2 lines for me relating options to another pages.
0
NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

 
LVL 19

Expert Comment

by:webwoman
ID: 7133709
You have to edit this yourself, FrontPage will NOT do any of it for you. And make sure it doesn't try to 'fix' it..

You actually don't even need a button if you don't want one. If you use this...
 <select name="choices" onChange="javascript:window.location.href=document.site.choices.options[document.site.choices.selectedIndex].value">
You'll go to that place when you select something. You need to set the option value to the URL you want to go to.

There are a few ways you can do it using a button. It doesn't even really need to BE a button, it can be just a graphic set as a link. Use an onclick to call a function.

I haven't tested this. It needs to go in the HEAD tags.
<script language="javascript">
function goHere(url) {
url=document.site.choices.options[document.site.choices.selectedIndex].value
window.location.href=url;
}
</script>
where site is the form name, choices is the select name (that applies for the other piece of script too)

And on the image (not a button) you'd use
onclick="goHere('your_url_here')"

I didn't post anything more than what I did because you didn't say WHY you wanted an image button or what you were trying to do. I suspect this is going to be very confusing for you. There's ALWAYS more than one way to do something, and the more detail you can give on what you want to do the better answer you're going to get.

And I'm not sure you are comfortable with editing the code directly -- always a concern for anyone who posts in this topic area.
0
 

Author Comment

by:MOSTAGHASSI
ID: 7134026
hi

Yes i'm comfortable for written codes and tomorrow test these codes.

I had another question about using button from flash in frontpage(2 day ago) that was not possible for hyperlink and u answered that i must publish as animated gif ,but now i have to say that it does not work ,i donot have animation in this state but hyperlink is possible,i think there must be a way simple for using button from flash in frontpage.

Thank you
0
 
LVL 19

Expert Comment

by:webwoman
ID: 7134125
You publish the animated GIF from Flash, not FrontPage. It should be under the SAVE AS option. Once you have a GIF, you use it just like any GIF. Animated or not, it doesn't matter.

You're not going to see ANY animation while you're in FrontPage. NOTHING works while you're in FrontPage, not even FrontPage stuff.

If you're comfortable with codes, you might want to look at other web editors. FrontPage tends to add/change/'fix' things, sometimes conveniently breaking your code.

It's not just FP, all WYSI(N)WYG editors are like that.
0

Featured Post

Secure Your WordPress Site: 5 Essential Approaches

WordPress is the web's most popular CMS, but its dominance also makes it a target for attackers. Our eBook will show you how to:

Prevent costly exploits of core and plugin vulnerabilities
Repel automated attacks
Lock down your dashboard, secure your code, and protect your users

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Now that Expression Web 4.0 (http://www.microsoft.com/expression/products/Upgrade.aspx) is free if you buy or have the full version of Expression Web 3.0, now is the best time to  migrate from FrontPage to Expression Web (http://www.frontpage-to-exp…
When setting up new project requests for our site, one of the most powerful tools our team has available to use is Axure (http://www.axure.com/). It’s a tool for creating software and web prototypes that can function and interact as if it were the a…
The purpose of this video is to demonstrate how to automatically show related posts at the bottom of a blog post in WordPress. This will be demonstrated using a Windows 8 PC. Plugin “Yet Another Related Posts Plugin” will be used. Go to your…
The purpose of this video is to demonstrate how to update a WordPress Site’s version. WordPress releases new versions of its software frequently and it is important to update frequently in order to keep your site secure, and to get new WordPress…

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question