IE doesn't seem to recognize option click

try this in both FF and IE
$("select *").click(function () {
      alert(this.tagName);
    });

In FF will get alert returning "Option", in IE doesn't fire

try this:
$("#kies_land").change(function () {
        if ($(this).val()=="nederland") {
      $(".uitschuifgedeelte_land").slideToggle("slow");
      }
    });

Thavipa wrote:
Hi all,

For my work i need to make a form. At some points you have to choose
an option from a dropdown select box. After you have chosen one of
those some other field appear under the dropdown thing. I use the
slideToggle event for this effect.

In firefox its all working fine, but in ie 6.0 and 7.0 it doesnt work.

What do need:
A dropdown menu with a few options in it. You can choose one of those
and after you select it a few other options apear under the dropdown
menu.

Code: (this is the dropdown menu..)
<table width="445" border="0" cellpadding="0">
  <tr>
    <td width="200">Land*</td>
    <td width="245">
      <select name="kies_land" id="kies_land" class="lang">
      <option disabled="disabled" selected="selected">kies een land</
option>
      <option value="nederland" class="nederland">Nederland</option>
      <option value="belgie">Belgi&euml;</option>
      <option value="duitsland">Duitsland</option>
      </select>
    </td>
  </tr>
</table

For this example im using tables. I'm sorry...;)

(i have a display:none; in my css for this part..)
<div class="uitschuifgedeelte_land">
  <tr>
    <td width="200">Provincie*</td>
    <td width="245">
    <select name="kies_provincie" id="kies_provincie" class="lang">
    <option value="flevoland">Flevoland</option>
    <option value="gelderland">Gelderland</option>
    <option value="friesland">Friesland</option>
    </select>
    </td>
  </tr>
</div>

This is what needs to appear after you select something. I wrapped it
in a div, so its easier for me to call it in the <head>.

This is what i got in my <head></head>:
<script src=""></script>

  <script>
  $(document).ready(function(){

    $(".nederland").click(function () {
      $(".uitschuifgedeelte_land").slideToggle("slow");
    });

  });
  </script>

This code works fine in every browser except IE.. what i tried to do:
I made a <a href="" class="somerandom">test</a>
Just a link on some text.. this did work in IE, but how can i make a
make a link of an option from dropdown menu?

I hope some of you knows the anser.. i really hope so! I stuck in this
for hours...:(

Thavipa


  

Reply via email to