A few days ago I updated an old wordpress site of my client, after that, when I was going to add a custom post category to top menu, I found the “Screen Options” would not showing up. So I made a comparation with other wordpress installs, version 4.1.3 is working, english is working, japanese is working, but chinese version not.
The problem is on page “wp-admin/nav-menus.php”, first I thought it maybe some js conflict of chinese version, so I added
define('CONCATENATE_SCRIPTS', false);
to wp-config.php to load js seperately, it turns out the js files are exactly the same with other languages, but html structures are not.
I turned to dig the .po files, then found one mistake on line 949 of admin-zh_CN.po
#: wp-admin/users.php:395
msgid "%s user deleted."
msgid_plural "%s users deleted."
msgstr[0] "已删除%d个用户。"
Now I could confirm translation file do has errors, but there are 2000+ items, I only want to find out the screen option part, luckily firefox marked wrong html tags with red color, it’s easy to find out the wrong “strong” tag on line 1085 of admin-zh_CN.po
#: wp-admin/nav-menus.php:520
msgid ""
"To add a custom link, <strong>expand the Custom Links section, enter a URL "
"and link text, and click Add to Menu</strong>"
msgstr ""
"要添加自定义链接,<strong>展开自定义链接小节,输入URL和链接文本,然后点击添加"
"到菜单<strong>"
After correction, I use poedit to regenerate admin-zh_CN.mo then overwrite it with ftp.
Tada! the “Screen Options” works as normal.
Here is the fixed admin-zh_CN.po and admin-zh_CN.mo
languages
Translation is tedious and everyone may make a typo, that’s quite understandable.