Make WordPress Core


Ignore:
Timestamp:
10/17/2003 07:26:05 PM (23 years ago)
Author:
emc3
Message:

Applying patches from otaku42: Fix two bugs in images uploads. Fix time_difference limitations.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/b2-include/b2functions.php

    r455 r456  
    12851285}
    12861286
     1287
     1288// implementation of in_array that also should work on PHP3
     1289if (!function_exists('in_array')) {
     1290
     1291    function in_array($needle, $haystack) {
     1292        $needle = strtolower($needle);
     1293       
     1294        for ($i = 0; $i < count($haystack); $i++) {
     1295        if (strtolower($haystack[$i]) == $needle) {
     1296            return true;
     1297        }
     1298        }
     1299   
     1300        return false;
     1301    }
     1302}
     1303
    12871304?>
Note: See TracChangeset for help on using the changeset viewer.