Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6984093
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T18:30:19+00:00 2026-05-27T18:30:19+00:00

Ok so I have a bit o’ script that works in FF but not

  • 0

Ok so I have a bit o’ script that works in FF but not IE or chrome. The basic idea is that when you select one of the options from the drop down menu it will switch to another relevant option in the menu below. (it’s in a paypal order form)

You can see it in action here – http://www.bizzaromatic.smappdooda.com/xtra/dvd.html

I figured out that FF will accept an onclick event in an option field but not IE or Chrome. Problem is now I can’t figure out how to make the code work to select the right options. Any help would be great.

Added code

Javascript:

<script type="text/javascript">
function displayResult()
{
document.getElementById("price").selected=true;
}
function displayResult2()
{
document.getElementById("dvd").selected=true;
}
</script>

HTML

    <form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="hosted_button_id" value="HGJ99G982KAEL">
<table>
<tr><td><input type="hidden" name="on0" value="Select One">Select One</td></tr><tr><td><select name="os0">
    <option value="DVD" onclick="displayResult2()">DVD $25.00 USD</option>
    <option value="DVD w/ 1 CCSB" onclick="displayResult()">DVD w/ 1 CCSB $35.00 USD</option>
    <option value="DVD w/ 2 CCSB" onclick="displayResult()">DVD w/ 2 CCSB $40.00 USD</option>
</select> </td></tr>
<tr><td><input type="hidden" name="on1" value="Options">Options</td></tr><tr><td><select name="os1">
    <option value="DVD Only" id="dvd">DVD Only</option>
    <option value="Red/Green" id="price">Red/Green</option>
    <option value="Red/Yellow">Red/Yellow </option>
    <option value="One of Each">One of Each</option>
    <option value="Surprise Me">Surprise Me!</option>
</select> </td></tr>
</table>
<br><input type="hidden" name="currency_code" value="USD">
<input type="image" src="http://www.bizzaromatic.smappdooda.com/xtra/images/dvd.jpg" border="0" name="submit" title="Buy the DVD"><br><font size=2>Click to order</font>
</form>
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T18:30:20+00:00Added an answer on May 27, 2026 at 6:30 pm

    You can solve it by adding an onchange event handler for your <select> element rather than a click handler for your <option> elements.

    Change your <select> to:

    <select name="os0" onchange="applyChange(this)">
      <option selected="selected" value="DVD">DVD $25.00 USD</option>
      <option value="DVD w/ 1 CCSB">DVD w/ 1 CCSB $35.00 USD</option>
      <option value="DVD w/ 2 CCSB">DVD w/ 2 CCSB $40.00 USD</option>
    </select>
    

    And add the following function in your <script> block (you can replace the functions displayResult() and displayResult2() with this single function):

    function applyChange(obj) {
      if(obj.value == 'DVD') {
        document.getElementById("dvd").selected=true;
      }
      else {
        document.getElementById("price").selected=true;
      }
    }
    

    The above changes will make your page work as expected on all browsers (including IE7!)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a bit of script that I think is nearly there. I have
I have a bit of an issue that I am not sure how to
I have a bit of a mystery here that I am not quite understanding
i have bit of code that causes an underflow: var t1, t2, delta: DWORD:
I have a bit of code that basically reads an XML document using the
I have a bit of code that passes around a ton of objects and
I have this bit of script to widen a text box on mouseover and
I have a bit of code that looks like this: text = reg.Replace(text, new
I have a bit of a question that has been bothering me for a
I have a bit of code to grab some information from WMI in C#,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.