Permalinks are the permanent URLs to your individual weblog posts, as well as categories and other lists of weblog postings. A permalink is what another weblogger will use to link to your article (or section), or how you might send a link to your story in an e-mail message. The URL to each post should be permanent, and never change — hencepermalink.


(string) A link to the post. Note: One cannot rely upon the GUID to be the permalink (as it previously was in pre-2.5), Nor can you expect it to be a valid link to the post. It’s mearly a unique identifier, which so happens to be a link to the post at present.


在Google里搜了很久,发现guid几乎只在WordPress的RSS中用到,在WordPress的fr:Marqueurs de Modele里可以找到这个函数

Affiche le nom d’une ou plusieurs catégories auxquelles appartient l’article au format RSS (en anglais). Ce marqueur doit être utilisé à l’intérieur de la Boucle.

<?php the_category_rss(‘type’) ?>


Simply put, the GUID can be thought of as an unique ID — WP uses URIs and if you happen to change your URI, the GUID will not update because simply put, it does not need to.

However ‘sloppy’ this may appear it will not matter because as an example where the GUID appears in your RSS2 feed you will note: isPermaLink="false" which as stated by the spec:

isPermaLink is optional, its default value is true. If its value is false, the guid may not be assumed to be a url, or a url to anything in particular. (http://blogs.law.harvard.edu/tech/rss#ltguidgtSubelementOfLtitemgt)

So fear not, the GUIDs in your DB (though they may look sloppy because of a URI change) will not hurt you 🙂



1. WrodPress的.htaccess文件要开放写权限,这个可通过FTP工具进行设置

2. 在Apache的httpd.conf文件中找到LoadModule rewrite_module modules/mod_rewrite.so,取消前面的#

3. 同样在httpd.conf中查找指向WordPress安装目录的Directory tag,对其中的AllowOverride参数设置为FileInfo,关于AllowOverride的详细介绍,可参见http://www.phperz.com/server/Apache/102H05320092053.html

One of the JavaIdioms, “Double Brace Initialization”

Objects created by DoubleBraceInitialization will never be equal to objects created without it. So you would never use this for any class that needs a nontrivial equals(Object)method.

public class DoubleBraceInitialization {
    private String str;

    public DoubleBraceInitialization() {
        str = "double brace initialization";
     * @return the str
    public String getStr() {
        return str;

     * @param str the str to set
    public void setStr(String str) {
        this.str = str;

    /* (non-Javadoc)
     * @see java.lang.Object#hashCode()
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((str == null) ? 0 : str.hashCode());
        return result;
    /* (non-Javadoc)
     * @see java.lang.Object#equals(java.lang.Object)
    public boolean equals(Object obj) {
        if (this == obj) {
            return true;
        if (obj == null) {
            return false;
        if (getClass() != obj.getClass()) {
            System.out.print("Because " + this.getClass().getName() + "is different from " + obj.getClass().getName() + " , so answer is ");
            return false;
        DoubleBraceInitialization other = (DoubleBraceInitialization) obj;
        if (str == null) {
            if (other.str != null) {
                return false;
        } else if (!str.equals(other.str)) {
            System.out.print("Because str in " + this.getClass().getName() + "is different from " + obj.getClass().getName() + "'s, so answer is ");
            return false;
        return true;

    public static void main(String[] args) {
        DoubleBraceInitialization dbi1 = new DoubleBraceInitialization() {{
                this.setStr("double brace initialization");
        DoubleBraceInitialization dbi2 = new DoubleBraceInitialization();
        System.out.println("dbi1 vs dbi2 : " + dbi1.equals(dbi2));

Standard out print:
Because DoubleBraceInitialization$1is different from DoubleBraceInitialization , so answer is dbi1 vs dbi2 : false


Taste of String

String is always a popular topic in java. Beyond all question String is an object type. But sometimes it seems like a basic data type. Many website emphasize we should identify between one situation when we use String a = “abc” and the other when String a = new String(“abc”).

Why I say String sometimes looks like a basic data type. Let’s see a simple example first:

Continue reading Taste of String

互联网常见Open API文档资源(转)

      所谓的开放API(OpenAPI)是服务型网站常见的一种应用,网站的服务商将自己的网站服务封装成一系列API(Application Programming Interface,应用编程接口)开放出去,供第三方开发者使用,这种行为就叫做开放网站的API,所开放的API就被称作OpenAPI(开放API)。

      网站提供开放平台的API后,可以吸引一些第三方的开发人员在该平台上开发商业应用,平台提供商可以获得更多的流量与市场份额,第三方开发者不需要庞大的硬件与技术投资就可以轻松快捷的创业,从而达到双赢的目的,开放API是大平台发展、共享的途径,让开发者开发一个有价值应用,付出的成本更少,成功的机会更多。今天,OpenAPI作为互联网在线服务的发展基础,已经成为越来越多互联网企业发展服务的必然选择。下面我就列举一些常见网站服务的Open API文档资源索引。

Continue reading 互联网常见Open API文档资源(转)





Continue reading 深圳留学生创业大厦

Wanna be Your Code

If you are a programmer.

If you hearts have bounded together.

I’m not advertising for ms. But if you match the conditions above, you may share the feeling with me…

(To watch the movie you have to Install Silverlight(windows, mac) and knowledge about Persian Password if you want to know more)

Get Microsoft Silverlight

Treasure everything you have.

Google gone

This is a memorible day. Once I use Google to search information for at least 10 times everyday. He’s now finally gone.

Almost each dormate and dormates in the next dormitory just know baidu when I first in this school. But now they believe Google is better then Baidu and they all turned to use Google now. I told them Baidu is only for the guy who know nothing but entertaments and jokes. They just hang around the internet with no purpose.

Something is true from the fact that if you want to find the official information, you have to be more patient to look for it from the result provided by baidu. But Google is different. There is no other explaination for the question why baidu don’t put the most official information on the first place. Because baidu don’t consider you should know facts from origin. It may want you to tell the true or express your opinion upon other opinion. But can it possible to tell the true from this stupit way?

I always in favour of the attitude of Google towards the internet information. The pure information should provide for anyone first because you and me have the right to know what is a thing on earth.

In any case, the good new is you can still access to Google from the domain of HK, called the new Google home. Once upon a time, many and many strong men have devote themselves into this game making a wonderful situation in China with many new technoledge.

Now, http://www.google.cn/music/homepage is still remain normal when I’m writing this page. Can this address remind you the history of www.google.cn? Let’s pray for god and stay together around this site: http://www.google.com/prc/report.html.