In array (opus): Difference between revisions
Jump to navigation
Jump to search
New page: function in_array(string, array) { if( !string || !array) { logError('in_array() >> Not enough arguments supplied'); return false; } var arrLength = array.length var i = 0 while( ... |
No edit summary |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
<pre> | |||
function in_array(string, array) | function in_array(string, array) | ||
{ | { | ||
Line 13: | Line 11: | ||
return false; | return false; | ||
} | } | ||
</pre> |
Latest revision as of 10:16, 26 April 2007
function in_array(string, array) { if( !string || !array) { logError('in_array() >> Not enough arguments supplied'); return false; } var arrLength = array.length var i = 0 while( i < arrLength ) { if(array[i]==string) return true; i++; } return false; }