var item1 = function() {
var item1 = 'ITEM1 HERE';
var item2 = 'THE REST HERE';
if what_to_put_here() {
return item1;
} else if what_to_put_here {
return item2;
}
};
item1 = the first loop will have complete contents
item2 = from 2nd and the rest of the loop will have partial contents
Hi, I have a loop and I want the first loop to be different from the rest of the loop. I am still learning javascript by myself. Though google is there but I do not know the term/words to use. My questions, Is the code above is the right format? What are the functions to be used? Pls help. thanks in advance!