Make WordPress Core


Ignore:
Timestamp:
12/03/2004 02:38:11 AM (22 years ago)
Author:
rboren
Message:

Move rewrite and permalink functions into WP_Rewrite class.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/admin-functions.php

    r1894 r1908  
    491491
    492492function save_mod_rewrite_rules() {
    493         global $is_apache;
     493        global $is_apache, $wp_rewrite;
    494494        $home = get_settings('home');
    495495        if ( $home != '' && $home != get_settings('siteurl') ) {
     
    507507                $writable = false;
    508508
    509         $permalink_structure = get_settings('permalink_structure');
    510 
    511         if ( strstr($permalink_structure, 'index.php') ) // If they're using
     509        if ($wp_rewrite->using_index_permalinks())
    512510                $usingpi = true;
    513511        else
     
    515513
    516514        if ( $writable && !$usingpi && $is_apache ) {
    517                 $rules = explode("\n", mod_rewrite_rules($permalink_structure));
     515                $rules = explode("\n", $wp_rewrite->mod_rewrite_rules());
    518516                insert_with_markers($home_path.'.htaccess', 'WordPress', $rules);
    519517        }
Note: See TracChangeset for help on using the changeset viewer.