Make WordPress Core

Opened 16 years ago

Closed 15 years ago

Last modified 15 years ago

#2785 closed defect (bug) (fixed)

wp-includes/classes.php loop not incrementing $tok_index

Reported by: debuntu Owned by:
Milestone: Priority: normal
Severity: trivial Version: 2.0
Component: General Keywords: has-patch
Focuses: Cc:

Description

It seems that something is missing in wp-includes/classes.php . At line 1022:

$tok_index = 1;

foreach ($tokens[0] as $token) {

if ( ($token == '%post_id%') && ($tok_index <= 3) ) {

$front = $front . 'date/';
break;

}

}

$tok_index is never increased?!? This force writing "date/" in front of archives pages.
there should be $tok_index++ after the if(){} condition.
Check this thread:
http://wordpress.org/support/topic/67914

Attachments (2)

2785.diff (336 bytes) - added by Nazgul 15 years ago.
2785_20.diff (338 bytes) - added by Nazgul 15 years ago.

Download all attachments as: .zip

Change History (5)

@Nazgul
15 years ago

@Nazgul
15 years ago

#1 @Nazgul
15 years ago

  • Keywords has-patch added
  • Milestone set to 2.0.5

Pacthes for 2.0 and trunk attached which implement the fix mentioned in the ticket.

#2 @ryan
15 years ago

  • Resolution set to fixed
  • Status changed from new to closed

(In [4279]) Increment tok_index. fixes #2785

#3 @(none)
15 years ago

  • Milestone 2.0.5 deleted

Milestone 2.0.5 deleted

Note: See TracTickets for help on using tickets.