471,091 Members | 1,553 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,091 software developers and data experts.

DHTML + Mac question

Hi,
I have an html page P that contains a iframe I.
In the same page i have two combobox, C1 and C2.
I would to load data in combo C2 after a choice by user over C1.
So I have created a jsp that get data from a DB and then build a page with
javascript code to update C2.

Foreach data I create an option with parent.document.createElement('option')
and then with an appenChild I update C2.

It worksfine on IE, Netscape (7) and Mozilla FireFox on PC, but doesn't work
in IE and Mac.
Why?
Can anybody know an alternative way to do the same thing without the reload
of P?

Thanks a lot
Ktrl+S
Jul 23 '05 #1
2 1107
Lazy70 wrote:
Hi, <snip>
Foreach data I create an option with parent.document.createElement('option')
and then with an appenChild I update C2.
You may use, assuming form named "f", and a menu/list named "s":

document.f.s.options[document.f.s.options.length] =
new Option("Option text here","Option value here(optional)")

Mick

It worksfine on IE, Netscape (7) and Mozilla FireFox on PC, but doesn't work
in IE and Mac.
Why?
Can anybody know an alternative way to do the same thing without the reload
of P?

Thanks a lot
Ktrl+S

Jul 23 '05 #2
"Mick White" <mw******@BOGUSrochester.rr.com> wrote in message
news:Mh********************@twister.nyroc.rr.com.. .
Lazy70 wrote:
Hi,

<snip>

Foreach data I create an option with parent.document.createElement('option') and then with an appenChild I update C2.


You may use, assuming form named "f", and a menu/list named "s":

document.f.s.options[document.f.s.options.length] =
new Option("Option text here","Option value here(optional)")

Mick


Thanks, now I try
I hope works ;)

Bye
Ktrl+S
Jul 23 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

2 posts views Thread by Frances Del Rio | last post: by
3 posts views Thread by adrian suri | last post: by
2 posts views Thread by | last post: by
20 posts views Thread by cwdjrxyz | last post: by
17 posts views Thread by Jacques Jamain | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.