标签:设置 gif auto ati option remove set pipe 默认
This document assumes familiarity with Apache‘s mod_rewrite. If you‘ve never heard of this before, try reading Sitepoint‘s Beginner‘s Guide to URL Rewriting. Also see Otto‘s explanation of hierarchy of rewrite rules in the wp-hackers email list.
本文档假定熟悉Apache的mod_rewrite模块。如果你从来没有听说过这个,试着读SitePoint的初学者指南URL重写。还看到Otto的解释层次结构的重写规则,在WP黑客电子邮件列表。
WP_Rewrite is WordPress‘ class for managing the rewrite rules that allow you to use Pretty Permalinks feature. It has several methods that generate the rewrite rules from values in the database. It is used internally when updating the rewrite rules, and also to find the URL of a specific post, Page, category archive, etc.. It‘s defined in wp-includes/rewrite.php as a single instance global variable, $wp_rewrite, is initialised in wp-settings.php.
wp_rewrite是WordPress的类管理的重写规则,允许你使用更好的永久链接功能。它有几种方法从数据库中的值生成重写规则。它在更新重写规则时在内部用,也可以找到特定的文章、页面、分类归档等的URL。它定义 wp-includes/rewrite.php作为单实例的全局变量,$wp_rewrite, 初始化在 wp-settings.php.
This is the formal documentation of WP_Rewrite. Try not to access or set the properties directly, instead use the methods to interact with the $wp_rewrite object. See also Rewrite_API.
这是wp_rewrite正式文件。尽量不要访问或直接设置属性,而使用$wp_rewrite对象的方法进行交互。又见rewrite_api(中文)。
$permalink_structure 固定链接结构
The permalink structure as in the database. This is what you set on the Permalink Options page, and includes ‘tags‘ like %year%, %month% and %post_id%.
数据库中的固定链接结构。你可以在选项页面去设置,包括“标签”像 %year%, %month% and %post_id%。
$category_base 分类的基础路径
Anything to be inserted before category archive URLs. Defaults to ‘category/‘.
在类别归档URL之前插入的内容。默认是 ‘category/‘。
$category_structure 分类归档的结构
Structure for category archive URLs. This is just the $category_base plus ‘%category%‘.
类别归档URL的结构。这仅仅是 $category_base 加上 ‘%category%‘。
$author_base 作者的基础路径
Anything to be inserted before author archive URLs. Defaults to ‘author/‘.
在作者归档URL之前插入的内容。默认是 ‘author/‘。
$author_structure 作者归档的结构
Structure for author archive URLs. This is just the $author_base plus ‘%author%‘.
作者归档URL的结构。这仅仅是 $author_base 加上 ‘%author%‘ 。
$pagination_base 分页的基础路径
Anything to be inserted before pagination indices. Defaults to ‘page/‘.
在分页索引之前插入的内容. 默认是 ‘page/‘ 。
$feeds 订阅
Supported feeds names (rdf, rss, atom) Use add_feed to override or add.
支持订阅的名字(rdf, rss, atom)使用add_feed重写或添加。
$feed_base 订阅的基础路径
Anything to be inserted before feed URLs. Defaults to ‘feed/‘.
在订阅URL之前插入的内容。默认是 ‘feed/‘。
$feed_structure 订阅的结构
订阅URL的结构. 这仅仅是 $feed_base 加上 ‘%feed%‘.
$search_base 搜索的基础路径
Anything to be inserted before searches. Defaults to ‘search/‘.
在搜索URL之前插入的内容. 默认是 ‘search/‘。
$search_structure 搜索的结构
Structure for search URLs. This is just the $search_base plus ‘%search%‘.
搜索URL的结构. 这仅仅是 $search_base 加上 ‘%search%‘.
$comments_base 评论的基础路径
Anything to be inserted just before the $feed_structure to get the latest comments feed. Defaults to ‘comments‘.
在最新评论订阅之前插入的内容。默认是‘comments‘。
$comments_feed_structure 评论订阅的结构
最新评论订阅的结构.。这仅仅是 $comments_base 加上 $feed_base plus ‘%feed%‘。
$date_structure 日期的结构
Structure for dated archive URLs. Tries to be ‘%year%/%monthnum%/%day%‘, ‘%day%/%monthnum%/%year%‘ or ‘%monthnum%/%day%/%year%‘, but if none of these are detected in your $permalink_structure, defaults to ‘%year%/%monthnum%/%day%‘. Various functions use this structure to obtain less specific structures: for example, get_year_permastruct() simply removes the ‘%monthnum%‘ and ‘%day%‘ tags from $date_structure.
日期档案URL的结构。尝试 ‘%year%/%monthnum%/%day%‘,‘%day%/%monthnum%/%year%‘ or ‘%monthnum%/%day%/%year%‘, 但是,如果这些都不是你检测的$permalink_structure,默认是 ‘%year%/%monthnum%/%day%‘。各种功能使用这些结构去获取更少的具体结构。例如,get_year_permastruct()简单的移除 %monthnum%‘ 和 ‘%day%‘ 标签,对于$date_structure。
$page_structure 页面的结构(别名)
Structure for Pages. Just ‘%pagename%‘.
页面的结构。仅仅是 ‘%pagename%‘。
Anything up to the start of the first tag in your $permalink_structure.
在你的$permalink_structure第一个标签前插入的内容。
$root
The root of your WordPress install. Prepended to all structures.
WordPress安装的根目录。所有结构的前缀。
$matches
Used internally when calculating back references for the redirect part of the rewrite rules.
在计算重写规则重定向部分的回引用时,使用在内部。
$rules
The rewrite rules. Set when rewrite_rules() is called.
重写规则。当rewrite_rules()调用时。
$non_wp_rules
Associative array of "rules that don‘t redirect to WP‘s index.php (and thus shouldn‘t be handled by WP at all)" roughly in the form ‘Pattern‘ => ‘Substitution‘
(see below).
一个关联数组。"不要重定向到 WP的 index.php(因此不应该被WP处理。)" 。粗略的结构是 ‘Pattern‘ => ‘Substitution‘(见下文)。
$rewritecode
An array of all the tags available for the permalink structure. See Using Permalinks for a list.
一个数组,所有的标签可用于固定链接。看看使用Permalinks列表。
1 public ‘rewritecode‘ => 2 array 3 0 => string ‘%year%‘ (length=6) 4 1 => string ‘%monthnum%‘ (length=10) 5 2 => string ‘%day%‘ (length=5) 6 3 => string ‘%hour%‘ (length=6) 7 4 => string ‘%minute%‘ (length=8) 8 5 => string ‘%second%‘ (length=8) 9 6 => string ‘%postname%‘ (length=10) 10 7 => string ‘%post_id%‘ (length=9) 11 8 => string ‘%author%‘ (length=8) 12 9 => string ‘%pagename%‘ (length=10) 13 10 => string ‘%search%‘ (length=8) 14 11 => string ‘%category%‘ (length=10) 15 12 => string ‘%post_tag%‘ (length=10) 16 13 => string ‘%post_format%‘ (length=13)
标签:设置 gif auto ati option remove set pipe 默认
原文地址:http://www.cnblogs.com/kais7mg/p/7736552.html