Generates rewrite rules with permalink structure and walking directory only.
Description
Shorten version of WP_Rewrite::generate_rewrite_rules() that allows for shorter list of parameters. See the method for longer description of what generating rewrite rules does.
See also
- WP_Rewrite::generate_rewrite_rules(): See for long description and rest of parameters.
Parameters
$permalink_structure
stringrequired- The permalink structure to generate rules.
$walk_dirs
booloptional- Whether to create list of directories to walk over.
Default:
false
Source
public function generate_rewrite_rule( $permalink_structure, $walk_dirs = false ) {
return $this->generate_rewrite_rules( $permalink_structure, EP_NONE, false, false, false, $walk_dirs );
}
Changelog
Version | Description |
---|---|
1.5.0 | Introduced. |
User Contributed Notes
You must log in before being able to contribute a note or feedback.