[wp-hackers] page(\d+) slugs
Steve Taylor
steve at sltaylor.co.uk
Tue Oct 26 13:25:17 UTC 2010
A client's site has just broken in a major way and I've tracked it
down to a change in WP 3. Line 2561 in /wp-includes/post.php:
if ( $post_name_check || in_array( $slug, $feeds ) || preg_match(
'@^(page)?\d+$@', $slug ) ) {
It's the last condition. My client's site has sections for different
conferences they run, and each conference year's landing page has a
slug set to the year of the conference, e.g. "2010". The whole system
is based on this, and it was working fine. Now when they update a
landing page, the numerical slug isn't allowed, and gets set to
something like "2010-2".
I can't find the Trac ticket to explain this. Are numerical slugs now
not allowed?
For now I'm having to hack post.php, but obviously I'd like to find a
better solution (which doesn't involve recoding my client's site!).
cheers,
Steve
More information about the wp-hackers
mailing list