thanks everyone, i got it working under Firefox. however, it doesn't do
anything in IE ( i am testing it under 6.0) . i am using Sonny's
example.
J.
Sonny Savage wrote:
> The Javascript needs to execute after you define the element. You were
> trying to reference 'id2' before it existed.
>
> <html>
> <head>
> <script type="text/javascript" src="prototype.js"></script>
> </head>
> <body>
>
> <form>
> <select id="id1">
> <option value="">A</option>
> <option>B</option>
> </select>
> </form>
> <div id="id2""></div>
>
> <script type="text/javascript">
> new Form.Element.EventObserver( 'id1',function(ele,value){
> $('id2').innerHTML="test"; } );
> </script>
>
> </body>
> </html>
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-spinoffs
-~----------~----~----~----~------~----~------~--~---