Solved

loop jSON value in jquery

Posted on 2012-03-26
3
353 Views
Last Modified: 2012-03-26
Hey all how can i set this up for a loop?
data.row9_1 

Open in new window


I cant seem to do it this way:
 var $theRowCount; 
 
 $theRowCount = 9; 
 
 while($theRowCount < 30){ 
    $('#row' + $theRowCount + '_1').html(data.row + $theRowCount + '_1'); 
    $theRowCount ++; 
 } 

Open in new window

Any ideas would be great!

David
0
Comment
Question by:Stealthrt
  • 2
3 Comments
 
LVL 82

Accepted Solution

by:
leakim971 earned 200 total points
Comment Utility
 var $theRowCount; 
 
 $theRowCount = 9; 
 
 while($theRowCount < 30){ 
    $('#row' + $theRowCount + '_1').html(data[ 'row' + $theRowCount + '_1' ]); 
    $theRowCount ++; 
 } 

Open in new window

0
 

Author Closing Comment

by:Stealthrt
Comment Utility
Awesome! Thanks :o)
0
 
LVL 82

Expert Comment

by:leakim971
Comment Utility
you're welcome!
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

Introduction HTML checkboxes provide the perfect way for a web developer to receive client input when the client's options might be none, one or many.  But the PHP code for processing the checkboxes can be confusing at first.  What if a checkbox is…
Batch, VBS, and scripts in general are incredibly useful for repetitive tasks.  Some tasks can take a while to complete and it can be annoying to check back only to discover that your script finished 5 minutes ago.  Some scripts may complete nearly …
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)

728 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now