Welcome to Gaia! ::

My Design :: Web and Graphic Design [HTML CSS PHP]

Back to Guilds

XHTML, CSS, jQuery, Javascript, PHP, mySQL, MORE! 

Tags: design, graphics, html, jquery, javascript 

Reply Client Side Scripting
js and arrays

Quick Reply

Enter both words below, separated by a space:

Can't read the text? Click here

Submit

DForck42

PostPosted: Sun Feb 04, 2007 7:43 pm


i once tried to make a minesweeper game in js, but i couldn't get it to support a 2d array

is there a way to make a 2d array, or is it pretty much pointless?
PostPosted: Sun Mar 11, 2007 11:28 pm


Of course you can make a 2-dimensional array. Why would it restrict you from putting Array objects in an Array object?

var array = new Array()
array[0] = new Array()
array[0][0] = 'foo';


Using "[]" instead of "new Array()" would work too.

Edit: This post was not intended to sound mean or anything.

Peng

Reply
Client Side Scripting

 
Manage Your Items
Other Stuff
Get GCash
Offers
Get Items
More Items
Where Everyone Hangs Out
Other Community Areas
Virtual Spaces
Fun Stuff
Gaia's Games
Mini-Games
Play with GCash
Play with Platinum