Make WordPress Core


Ignore:
Timestamp:
03/21/2008 04:10:01 AM (18 years ago)
Author:
markjaquith
Message:

better Apache mod detection from andy. fixes #6278

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/misc.php

    r6551 r7441  
    22
    33function got_mod_rewrite() {
    4         global $is_apache;
    5 
    6         // take 3 educated guesses as to whether or not mod_rewrite is available
    7         if ( !$is_apache )
    8                 return false;
    9 
    10         if ( function_exists( 'apache_get_modules' ) ) {
    11                 if ( !in_array( 'mod_rewrite', apache_get_modules() ) )
    12                         return false;
    13         }
    14 
    15         return true;
     4        return apache_mod_loaded('mod_rewrite');
    165}
    176
Note: See TracChangeset for help on using the changeset viewer.