hi! i only want to know how to get the value of the array in javascript using class?

<div class='view'>1</div>
<div class='view'>2</div>
<div class='view'>3</div>
<div class='view'>4</div>

Try this simple code.

<script type="text/javascript">
<!--
var myArray = new Array();

myArray[0] = "Football";
myArray[1] = "Baseball";
myArray[2] = "Cricket";

document.write(myArray[0] + myArray[1] + myArray[2]);
//-->
</script>

Apply it in your class...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.