Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

Javascript: How to test if response JSON array is empty

if( !$.isArray(siteArray) ||  !siteArray.length ) {
    //handler either not an array or empty array
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #How #test #response #JSON #array #empty
ADD COMMENT
Topic
Name
3+9 =