Change Language


Follow Navioo On Twitter

for...in

Loops through the properties of an object.

Syntax

for (objectVariable in object){
	statement
	}

Example

for (var catProperty in cat) {
	document.write(catProperty + " : " + cat[catProperty] + "
"); //writes the name and value of the properties in cat. }
text_javascript Navioo_docs

Examples -> Source code Demo online - > in:

Ajax Javascript feed

↑ Grab this Headline Animator