~canonical-sysadmins/wordpress/4.8.1

« back to all changes in this revision

Viewing changes to wp-includes/rewrite.php

  • Committer: Barry Price
  • Date: 2016-08-17 04:50:12 UTC
  • mfrom: (1.1.18 upstream)
  • Revision ID: barry.price@canonical.com-20160817045012-qfui81zhqnqv2ba9
Merge WP4.6 from upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
144
144
 * Add a new rewrite tag (like %postname%).
145
145
 *
146
146
 * The $query parameter is optional. If it is omitted you must ensure that
147
 
 * you call this on, or before, the 'init' hook. This is because $query defaults
 
147
 * you call this on, or before, the {@see 'init'} hook. This is because $query defaults
148
148
 * to "$tag=", and for this to work a new query var has to be added.
149
149
 *
150
150
 * @since 2.1.0
202
202
function add_permastruct( $name, $struct, $args = array() ) {
203
203
        global $wp_rewrite;
204
204
 
205
 
        // backwards compatibility for the old parameters: $with_front and $ep_mask
 
205
        // Back-compat for the old parameters: $with_front and $ep_mask.
206
206
        if ( ! is_array( $args ) )
207
207
                $args = array( 'with_front' => $args );
208
208
        if ( func_num_args() == 4 )
311
311
}
312
312
 
313
313
/**
314
 
 * Filter the URL base for taxonomies.
 
314
 * Filters the URL base for taxonomies.
315
315
 *
316
316
 * To remove any manually prepended /index.php/.
317
317
 *
463
463
        global $wp_rewrite;
464
464
 
465
465
        /**
466
 
         * Filter the URL to derive the post ID from.
 
466
         * Filters the URL to derive the post ID from.
467
467
         *
468
468
         * @since 2.2.0
469
469
         *