Go Back   CodingForums.com > :: Client side development > JavaScript programming

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 12-07-2004, 12:01 AM   PM User | #1
tfortwit
New to the CF scene

 
Join Date: Dec 2004
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
tfortwit is an unknown quantity at this point
Images in Arrays

Hi

How can I place an image into an array?...I am VERY new to java script and have an assignment to write an online quiz, using the 'usual' multiple choice answer questions, which I have managed to do, but now have to replace the answers with multiple choice images (as answers), with radio button selection...an example of the array I'm using:

questions[1] = new Array();
questions[1][0] = "Winnie The Pooh is a:";
questions[1][1] = "Tiger";
questions[1][2] = "Bear";
questions[1][3] = "Donkey";
questions[1][4] = "Pig";

Many Thanks
Alison
tfortwit is offline   Reply With Quote
Old 12-07-2004, 03:10 AM   PM User | #2
hemebond
Senior Coder

 
Join Date: Jul 2004
Location: New Zealand
Posts: 1,315
Thanks: 0
Thanked 2 Times in 2 Posts
hemebond is an unknown quantity at this point
Code:
questions[1][1] = new Image();
hemebond is offline   Reply With Quote
Old 12-07-2004, 11:19 PM   PM User | #3
tfortwit
New to the CF scene

 
Join Date: Dec 2004
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
tfortwit is an unknown quantity at this point
Thank you,

I will go and try it out
tfortwit is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:50 PM.


Advertisement
Log in to turn off these ads.