Wordpress 2.5 Released
March 29th, 2008 at 23:20 Posted in Blog Concerned, Tagged: Wordpress | No Comments »晕菜,只是刷新了一下WP主页,赫然发现已经改版,Wordpress2.5正式版已经放出。可怜Blue-box主题对Visual Editor有影响,大好的心情被破坏了。
where is the admin color scheme option
March 22nd, 2008 at 18:04 Posted in Blog Concerned, Tagged: Wordpress | No Comments »自从升级之后,我就一直苦苦寻找WP2.5的切换后台管理界面主题(Admin Color Scheme)功能。几乎点遍了后台所有能点的链接,睁大了眼睛也没发现到底在哪里切换Classic和Fresh这两种颜色搭配方案。“\wp-admin\css\”里的两个文件又确切地告诉我RC1版本并没有丢掉这个功能,最后还是在WordPress Support Forum里找到了答案,被藏在了“Users>Your Profile”里。之前寻找的时候恰恰只点到了Users,因为觉得最不可能把这个功能放在Your Profile下!
Users-Your Profile-the scheme-Update, you have to click four times to apply the new admin color scheme. Inconvenient.
WP升级至2.5RC1及若干
March 20th, 2008 at 23:48 Posted in Blog Concerned, Tagged: codes,Wordpress | No Comments »在Wordpress Blog上看到这句“The software is basically done and stable, and could be released today, but…”的时候,我决心等到WP2.5正式版放出再升级的坚定想法彻底消失,已经顾不上后面的but…, 鼠标直奔下载链接而去。
升级之前分别用”WordPress Database Backup“插件和自带的”Export“功能做了两个备份,2.5的改动似乎较大,保险起见没有覆盖上传,而是把2.3的文件直接挪到了一个临时文件夹中(为升级失败做准备,没有直接删除)。上传完毕后,页面正常打开,升级出乎意料地顺利,主题和插件也没有找麻烦。除后台界面面目基本全非外(居然没有找到Admin Color Scheme功能),还新增了”Add media“以及Simple Tag中已有的Tag Slug功能,好坏只能见仁见智。
早上偶然寻到一个很有才的wp theme作者,然后整个晚上就沉在眼花的代码中。成果颇丰,搞定random header image的同时还顺带找到如何用php表达css表单:
[ ?php echo(rand(1,5)); ?]
上面的代码很简单(google结果的第一条就是这个方法),随机在1~5之间生成一个数字。实现random header image效果只需要将图片放在同一路径下,命名采用数字区分,随机出哪个数字就显示对应的图片。不过遇到显示图片的代码写在css表单中的情况,除了将上段代码放进能够编译php的文件中执行来解决,只能想办法用.php文件格式来表达css表单,否则.css文件无法编译php代码。本来前一种方法很容易就搞定,但是之前用过的MK主题就是采用style.php的方式实现自定义主题颜色和宽度,这次又开始钻牛角尖。有示例做参考,几番折腾终于搞定:
在functions.php中加如下一段,
[ ?php function mytheme_wp_head() { ?]
[link href="[?php bloginfo('template_directory'); ?]/style.php” rel=”stylesheet” type=”text/css” /] [ ?php } add_action('wp_head', 'mytheme_wp_head'); ?][/link]
再将style.css改名为style.php,并在文件顶部加这么一条:
[ ?php require_once(dirname(__FILE__).'../../../../wp-config.php');
require_once(dirname(__FILE__).'/functions.php');
header("Content-type: text/css"); ?]
[和]分别替换为< 和>… 大功告成。
上次花费N个晚上修改前一个主题时,真没想到今天更换时会放弃得这么义无反顾。
update: 放弃了随机head image功能,因为发现会导致Visual Editor无法使用。具体原因不明,使用另一个同样以php格式定义css样式的主题却不会出现此问题。 更新了绿色部分,搞定…
WP2.5 has been delayed
March 11th, 2008 at 18:16 Posted in Blog Concerned, Tagged: Wordpress | No Comments »This is the NOTE in wordpress planet:
*Note* WordPress 2.5 was TENTATIVELY scheduled to be release on March 10th, 2008. However, it looks like it’s not ready for production treatment and thus, has not been released.
so the waiting continues…
update: for one week or even more.
Reupload wordpress files to solve live writer connection problem
December 9th, 2007 at 15:08 Posted in Blog Concerned, Tagged: WLW,Wordpress | 1 Comment »When WLW(2008version) connecting to wordpress 2.3.1, it returned this error:
尝试连接到日志时出错:
服务器响应无效-从日志服务器接收的对blogger.getUsersBlogs方法的响应无效():
Invalid response documnet returned from XmlRpc server
必须先纠正此错误才能继续操作
the English version is:
Error connecting to weblog
An error occurred while attempting to connect to your weblog;
invalid server resonse -the response to the bloger.getuserblogs method received form weblog server was invalid;
Invalid response document returned from xmlrpc server
You must correct this error before proceeding
I spent 2 days to looking for the solution. modify the .htaccess file, remove the blank near closing tag, use the default theme and deactivate all plugins, all those action did not work at all. Before contacting with my blog’s host, I delated all the wordpress files on the ftp but didnot clear the database and reuploaded, and then succeed! of course backup before that.
btw: before solving the problem, I have used fiddler to see what happened, and it returned a mismatch error:
Content-Length mismatch: Response Header claimed 531 bytes, but server sent 2938 bytes.
I don’t know why.
正在使用的Wordpress插件
November 20th, 2007 at 23:37 Posted in Blog Concerned, Tagged: plugins,Wordpress | No Comments »- Akismet anti-spam插件
- Audio Player
- Brian’s Threaded Comments 为留言增加回复功能
- Clean Archives Reloaded
- Comment Timeout anti spam的另一种方式
- Dofollow 这个可有可无,据说下个版本就直接是Dofollow了
- Feed Statistics 这个就顾名思义了,不过不准,还有2个功能似乎不能用
- Google XML Sitemaps 生成sitemap,用google webmastertools的话这个一定要用
- Lighter Admin Drop Menus 修改WP后台管理菜单为下拉样式,我在此基础上又修改了一下css
- MyDashboard 自定义Dashboard的插件
- No Self Pings
- Simple Tags 针对2.5的更新还没有出,disabled.
- SRG Clean Archives 见details页面的效果
- WordPress Database Backup 备份WP数据库,安全必备
- WP-PageNavi 为WP增加翻页功能
fake files on wordpress.org
October 14th, 2007 at 14:23 Posted in Blog Concerned, Tagged: Internet,plugins,Wordpress | 2 Comments »The fake files is about my dashboard 0.3.1version, and this is the download page on wordpress.org. After I saw the notification on the plugins mgmt page, I downloaded the plugin installation files, unzipped and uploaded to ftp, when I reactive this plugin, the missing “includes” folder made it fail.
Fortunately, the plugin’s home page offers the right files.
update: It has been fixed, so enjoy!
Wordpress文章数量判断函数
October 12th, 2007 at 23:51 Posted in Blog Concerned, Tagged: codes,Wordpress | 1 Comment »不是代码男,所以有点小成果就容易小兴奋。
simple tags插件可以提供related posts功能,但是现在使用的主题其首页和单篇文章共用了index.php这个模板,目标是只在浏览单篇文章时显示related posts,如果只添加<?php st_related_posts(); ?>显然无法完全满足要求,因为无法在首页控制它不显示出来。
在常去的几个技术blog中没有找到解决办法,无意在桑林志中看到了一些信息,又结合wordpress中文文档,终于得到如下代码:
<?php if ($single) {st_related_posts();} else {} ?>
加到index.php中,解决之。
Wordpress2.3升级成功
September 25th, 2007 at 10:45 Posted in Blog Concerned, Tagged: plugins,Wordpress | No Comments »官方的schedule是定于24日星期一发布2.3正式版的,昨晚等到00:00也不见动静。刚在twitter上发完wp跳票的小牢骚,refresh了一下页面就看到了2.3的字样。
升级过程中出了点小麻烦,后来乖乖访问http://example.com/wordpress/wp-admin/upgrade.php才成功打开页面。
不过新麻烦出现了:就在写这篇post的时候,自动保存时出现:
WordPress database error: [Table 'dbname.wp_post2cat' doesn't exist]
SELECT cat_ID AS ID, MAX(post_modified) AS last_mod FROM `wp_posts` p LEFT JOIN `wp_post2cat` pc ON p.ID = pc.post_id LEFT JOIN `wp_categories` c ON pc.category_id = c.cat_ID WHERE post_status = ‘publish’ GROUP BY cat_ID
先将就着罢
update: 上述错误的出现是由于Google Sitemap Generator的问题,禁用之后正常了(已更新到新版本)。——开始没有禁用插件,是以清空数据库为代价才发现的,还好备份能够恢复。
wp升级成功
July 12th, 2007 at 0:07 Posted in Blog Concerned, Journal, Tagged: Wordpress | No Comments »看到各种关于Movable Typ新版本的评论,再次手痒痒准备安装一下看看。在出现500 internet server error错误解决未果后联系west263的客服,检查发现是由于所有者的错误而导致的。此问题解决后又发现数据库模块缺失,对方再次手到病除——也许是客服的技术实力参差不齐,最初计划以mt搭建blog失败时多次联系都未成功解决问题。
用惯了wordpress,对mt的印象还停留在2.xxx版简洁的后台页面上。都在说mt4是在模仿wordpress,倒不如说mt在追赶wordpress的时候丢掉了自己风格路线。movable type的发展甚至还要早于wordpress,虽然后来由于收费、非开源而导致的插件数量少、安装不如wp简单等原因影响了更大规模的普及,但mt仍然不乏众多拥趸(dun),企业用户方面,intel的官方blog就是用的MT enterprise。
我把mt4装好之后只是简单测试了一下,像很多人说的一样,dashboard有wp的痕迹,但实质操作上还是有很大差别,保留了原来mt的操作味道,每次使用publish功能发布的时候都额外有成就感。还有就是似乎比wp提前支持了自带tag。可能是还不习惯的原因,dashboard的各功能菜单还不是很顺手,另外theme(style)的更换比较烦琐,自带的插件容易出现目录权限的错误。
如果同时用WP和MT分别照顾两个blog总觉得难以取舍,而且想不出分别写什么,更重要的是懒得再去研究mt的主题更换了(但还是十分喜欢多数MT blog的简洁风格),所以放弃了再同时用MT的念头。删掉文件,清理数据库之后,忽然想起这次西部数码帮忙重新配置了数据库的相关模块,可能上次升级WP时出现的错误不会再出现了。重新下载wp2.2.1,上传,upgrade,成功!一个差点想起来就让我产生放弃wp念头的麻烦终于解决了。因为要安装mt反而解决了wp的升级问题,真是歪打正着,十分感谢这个西部数码的技术支持,虽然是在QQ上联系的,但是效率还是比较高,尽管后来再提出的小问题没有回应,不过自己都感觉问得没完没了,所以已经可以理解了:D
另外现在已经亲自验证了西部数码的主机能够支持Wordpress和Movable Type,技术支持也不错,是很好的选择。



