What's going on with EZwpthemes? Well, well, well... now you got the right place - news of our WordPress themes site. Here you could get information about what have we done, which thing are we doing, and where will we go. Can't help to read on for more? Ok, I'm stopping blah-blah now. notice « “Free Resources” launched! To our readers »

WordPress 2.7.1 released!

Topic:

WordPress is upgraded once again. Version 2.7.1 is now available on WordPress’ official site.

Problem:

Some bugs are fixed, but unfortunately we find a new bug in this release. If your theme folder name contains character “-”, you’ll have a blank preview window from the admin control panel. However this doesn’t matter much, you can still activate your theme and use it without any trouble.

Reason:

wp-includes/theme.php is changed a little in order to support subdirectories of themes.
Details here: http://core.trac.wordpress.org/attachment/ticket/8548/themefix.diff
The newer regular expression supports “/” which refers to subdirectories. But the meaning of “-” is misunderstood, this caused preview error when theme folder name contains “-”.

Solution:

Simply change the string sequence:

Ver 2.7.1 original (which supports subdirectories, but doesn’t support “-” in directory name)
line 852 $_GET['template'] = preg_replace('|[^a-z0-9_.-/]|i', '', $_GET['template']);
line 860 $_GET['stylesheet'] = preg_replace('|[^a-z0-9_.-/]|i', '', $_GET['stylesheet']);

Ver 2.7.1, bug fixed
line 852 $_GET['template'] = preg_replace('|[^a-z0-9_./-]|i', '', $_GET['template']);
line 860 $_GET['stylesheet'] = preg_replace('|[^a-z0-9_./-]|i', '', $_GET['stylesheet']);

  • Digg
  • del.icio.us
  • StumbleUpon
  • Design Float
  • Reddit
  • Furl
  • Mixx
  • Technorati
  • BlinkList