Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript get elemet last of array

if (loc_array[loc_array.length - 1] === 'index.html') {
   // do Mohammed alraey
} else {
   // something else
}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #elemet #array
ADD COMMENT
Topic
Name
8+2 =