Fix attachment rewrite endpoints. Props Curioso. fixes #5553
git-svn-id: http://svn.automattic.com/wordpress/trunk@12271 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
5c5b0ddaff
commit
9f2fbbc2f9
|
@ -1444,10 +1444,10 @@ class WP_Rewrite {
|
||||||
$subcommentquery = $subquery . '&cpage=' . $this->preg_index(2);
|
$subcommentquery = $subquery . '&cpage=' . $this->preg_index(2);
|
||||||
|
|
||||||
//do endpoints for attachments
|
//do endpoints for attachments
|
||||||
if ( !empty($endpoint) ) { foreach ( (array) $ep_query_append as $regex => $ep ) {
|
if ( !empty($endpoints) ) { foreach ( (array) $ep_query_append as $regex => $ep ) {
|
||||||
if ($ep[0] & EP_ATTACHMENT) {
|
if ($ep[0] & EP_ATTACHMENT) {
|
||||||
$rewrite[$sub1 . $regex] = $subquery . '?' . $ep[1] . $this->preg_index(2);
|
$rewrite[$sub1 . $regex] = $subquery . $ep[1] . $this->preg_index(2);
|
||||||
$rewrite[$sub2 . $regex] = $subquery . '?' . $ep[1] . $this->preg_index(2);
|
$rewrite[$sub2 . $regex] = $subquery . $ep[1] . $this->preg_index(2);
|
||||||
}
|
}
|
||||||
} }
|
} }
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue