W

在wordpress文章中显示PHP代码

On 2010年02月3日, in 软件&应用, by 石头

把代码中的特殊符号改成html entities。 比如: 双引号 ” → & r d q u o ; 左尖括号 < → & l t ; 左尖括号 > → & g t ; (完整的符号–html entity对应表)。 往往你只需要改掉其中的左尖括号 < 就可以了。这样子php就不能运行它,它就可以正常显示了。在comment里也可以这样做。 阅读全文

Tagged with:  
W

[View with PicLens]自定义名称

On 2010年02月3日, in 软件&应用, by 石头

使用nextgen-gallery插件的时候,选择Image list 显示方式, 图片的上面总是显示“[View with PicLens]” 而Integrate slideshow的都可以自定义。 想自定这个名称吗? 只需简单修改下。 选择“插件”的“编辑”功能,选择要编辑的插件“nextgen-gallery”,找到文件 wp-content\plugins\nextgen-gallery\view\gallery.php 将 <?php _e(‘[View with PicLens]‘,’nggallery’); ?> 修改为 <?php _e(‘[全屏显示]‘,’nggallery’); ?> Enjoy. 阅读全文

Tagged with:  
W

Simple Tags 1.7.1-rc1.2 For WordPress 2.9.1 彩色云标签

On 2010年01月11日, in 软件&应用, by 石头

这次Simple Tags更新动作比较大,框架改变了不少,由于更新导致原来的彩色标签云失效,这里奉上简单设置方法。 WordPress 2.9.1 彩色标签云,Simple Tags 1.7.1 rc1.2 简单实现方法: 编辑simple-tags/inc/client.php 注释掉 $r = dechex(intval((($maxr - $minr) * $scale_color) + $minr)); $g = dechex(intval((($maxg - $ming) * $scale_color) + $ming)); $b = dechex(intval((($maxb - $minb) * $scale_color) + $minb)); 替换为 //Colorful Tag Cloud start $r = dechex(rand(0,255)); $g = dechex(rand(0,196)); $b = dechex(rand(0,255)); //Colorful Tag Cloud end 在外观–小工具中,添加Tag Cloud (Simple Tags)即可实现漂亮的彩色标签云。 阅读全文

Tagged with:  
W

更新WordPress 2.9 导致 Simple Tags 插件过期解决办法

On 2009年12月24日, in 软件&应用, by 石头

WordPress 2.9 提示: Simple Tags can’t work with this WordPress version! 其实也算不上不兼容,是插件作者多了一个 WordPress 版本强行检查的注释,最高版本检查 wp 2.8 已经写死(hard-coded)在里面了,还没来得及更新。解决方法,只要找到 simple-tags.php: 修改if ( strpos($wp_version, '2.7') !== false || strpos($wp_version, '2.8') !== false ) 为if ( strpos($wp_version, '2.7') !== false || strpos($wp_version, '2.9') !== false ) 阅读全文

Tagged with:  
W

Hello Dolly 另类玩法

On 2009年11月22日, in 软件&应用, by 石头

很是喜欢VeryCD那个标题头随机名言的效果,稍微读了下Hello Dolly的代码,发现用Wordpress自带的HD即可实现。 hello.tar 在 php wp_title 后面添加 hello_dolly2 ps.注意格式 把hello.php的内的XXX换成名言即可。 阅读全文

Tagged with: