09-07
14

PJ3不能发表评论BUG

将common/common.js文件中的函数
//初始化登陆态的表现 ,for static mode
function initLogin(CookieName){
...
}


替换成

//初始化登陆态的表现 ,for static mode
function initLogin(CookieName){
        var n = getCookie(CookieName);
        if (n) {
                //用户登陆
                var u = /memName=(\w+)/.exec(n);
                var ucn = /memName=([^\u4e00-\u9fa5]*)/.exec(n);
                var cnvalue = decodeURI(ucn[1]).split("&")[0];
                if (u){
                                var un = document.forms["frm"]["username"];
                                un.value = u[1];
                                un.readOnly = true;
                                if ($("passArea")) $("passArea").parentNode.removeChild($("passArea"));
                }else if(cnvalue.length > 0){
                                var cnun = document.forms["frm"]["username"];
                                cnun.value = cnvalue;
                                cnun.readOnly = true;
                                if ($("passArea")) $("passArea").parentNode.removeChild($("passArea"));
                }
                
                //blog目前的权限
                var m =  /memRight=(\d+)/.exec(n);
                if (m) {
                                var rn = parseInt(m[1],2);
                                
                                var ss = document.styleSheets[0];
                                var rule = ss.rules || ss.cssRules;
                                
                                if (rn&(1<<2) && rn&(1<<4)) rule[0].style.display = "";
                                if (rn&(1<<8)) {rule[1].style.display = "";}
                }
        }
}




文章来自: 本站原创
引用通告: 查看所有引用 | 我要引用此文章
Tags: PJ3 PJBLOG bug 评论
相关日志:
评论: 0 | 引用: 0 | 查看次数: 463
发表评论
昵 称:
密 码: 游客发言不需要密码.
内 容:
验证码: 验证码
选 项:
虽然发表评论不用注册,但是为了保护您的发言权,建议您注册帐号.
字数限制 1000 字 | UBB代码 开启 | [img]标签 关闭