هاست لینوکس

آخرین بسته‌ی MyBB: نسخه‌ی 1.8.27 MyBB منتشر شد


امتیاز موضوع:
  • 10 رأی - میانگین امتیازات: 3.8
  • 1
  • 2
  • 3
  • 4
  • 5
[برای 1.6] پلاگین اضافه کردن یادداشت در پروفایل Profile Comments
بله دوست عزیز فایل js داره و اپلود شده.
و منظورتون رو در مرحله بعد متوجه نشدم
من کد های js رو میزارم اگه منظورتون کدها هستند. یه نگاهی بندازید

کد php:
var Comments = {
    
init: function()
    {
        if($(
'sendcomment') && use_xmlhttprequest == 1)
        {
            
Event.observe($('sendcomment'), "click"Comments.sendComment.bindAsEventListener(this));
        }
    },

    
sendComment: function(e)
    {
        
// Don't use ajax if the user is replying to someone
        
if($('reply_to_profile').value != 'default' && $('reply_to_profile').value != current_user)
        {
            return 
false;
        }

        
Event.stop(e);

        if(
this.sending_comment)
        {
            return 
false;
        }

        
this.sending_comment 1;
        
this.spinner = new ActivityIndicator("body", {imageimagepath "/spinner_big.gif"});

        
// Get form data
        
postData "uid=" + $('to_uid').value "&reply_to_profile=" + $('reply_to_profile').value.replace(/\+/g"%2B");

        
// Get form data
        
if(editorloaded == 1)
        {
            
postData postData "&message=" encodeURIComponent($('message_new').value);
        }
        else
        {
            
postData postData "&message=" encodeURIComponent($('message').value);
        }
        
        new 
Ajax.Request('xmlhttp.php?action=profile&section=comments', {method'post'postBodypostDataonComplete: function(request) { Comments.sendCommentDone(request); }});

        if(
this.spinner)
        {
            
this.spinner.destroy();
            
this.spinner '';
        }
        
this.sending_comment 0;

        return 
false;
    },

    
sendCommentDone: function(request)
    {
        if(
request.responseText.match(/<redirect>(.*)<\/redirect>/))
        {
            
url request.responseText.match(/<redirect>(.*)<\/redirect>/);
            
window.location url[1];
        }
        else if(
request.responseText.match(/<error>([^<]*)<\/error>/))
        {
            
message request.responseText.match(/<error>([^<]*)<\/error>/);

            if(!
message[1])
            {
                
message[1] = "An unknown error occurred.";
            }

            if(
this.spinner)
            {
                
this.spinner.destroy();
                
this.spinner '';
            }
            
alert('There was an error posting your comment:\n\n'+message[1]);
        }
        else if(
request.responseText.match(/id="comment-([0-9]+)"/))
        {
            $(
'comment_form').insert({
                
'after'request.responseText
            
});

            
// Delete the "no comments" message
            
if($('no_comments_found'))
            {
                $(
'no_comments_found').remove();
            }

            
Form.reset('newcomment');
        }
        else
        {
            
alert('Unknown response');
        }
    },

};

if(
comments_ajax == 1)
{
    
Event.observe(document'dom:loaded'Comments.init);
}

Event.observe(window'load', function() {
    $$(
"a.reply").each(function(a)
    {
        
a.observe('click', function(c) {
            var 
username = $(this).readAttribute('username');
            var 
uid = $(this).readAttribute('userid');
            $(
'reply_to_profile').value uid;

            if(
editorloaded == 1)
            {
                
clickableEditor.performInsert('[b]' username '[/b], '''truefalse);
            }
            else
            {
                $(
'message').value += '[b]' username '[/b], ';
            }

            $(
'replyingto').update(replying_message.replace('{1}'username)).show();

            $(
'linkcancel').observe('click', function(c) {
                $(
'replyingto').hide();
                $(
'reply_to_profile').value 'default';
                
Event.stop(c);
            });

            
Event.stop(c);
        });
    });

    $$(
"a.delete_link").each(function(a)
    {
        
a.observe('click', function(c) {
            if(!
confirm(confirm_delete_message))
            {
                
Event.stop(c);
            }
        });
    });

}); 
www.pnuha.com
Email: info@pnuha.com
کارشناسی،ارشد،دکتری
تالار دانشجویان،فیلمها،تئاتر،گرافیک،گردشگری،موبایل،کامپیوتر،کتاب الکترونیکی،پیامک
[
[تصویر:  download.php?img=1207]
پاسخ


پیام‌های داخل این موضوع
RE: پلاگین اضافه کردن یادداشت در پروفایل Profile Comments - توسط !Omid StaR! - ۱۳۹۰/۱۰/۹، ۱۴:۱۰:۳۶ عصر
RE: پلاگین اضافه کردن یادداشت در پروفایل Profile Comments - توسط !Omid StaR! - ۱۳۹۰/۱۰/۱۶، ۰۹:۵۷:۵۱ صبح
RE: پلاگین اضافه کردن یادداشت در پروفایل Profile Comments - توسط snap - ۱۳۹۰/۱۱/۲۷، ۱۰:۱۳:۱۳ صبح
کمک مشکل بزرگ کمک کمک - توسط rondweb - ۱۳۹۱/۶/۱۴، ۰۶:۳۳:۵۴ صبح
کمک مشکل بزرگ کمک کمک - توسط rondweb - ۱۳۹۱/۶/۱۴، ۰۸:۰۹:۵۴ صبح

موضوع‌های مشابه…
موضوع نویسنده پاسخ بازدید آخرین ارسال
  [برای 1.6] پلاگین آخرین بازدیدکنندگان از پروفایل Last Visitors in Profile Pars 42 43,536 ۱۳۹۳/۵/۵، ۲۱:۴۳:۳۵ عصر
آخرین ارسال: reza.t.gh
Thumbs Up پروفایل به سبک وی بی profile tabs h0mayun 65 51,614 ۱۳۹۳/۲/۴، ۱۵:۳۹:۵۷ عصر
آخرین ارسال: vampire knight
  [برای 1.6] پلاگین لیست دوستان در پروفایل Profile Buddies Pars 42 36,186 ۱۳۹۳/۱/۱۷، ۱۳:۳۲:۵۸ عصر
آخرین ارسال: reza.t.gh
  [برای 1.6] پلاگین آلبوم های پروفایل Profile Albums 0.6 Cancer9003 32 29,647 ۱۳۹۲/۵/۵، ۱۴:۵۳:۴۳ عصر
آخرین ارسال: S!AvAsH
  [برای 1.6] پلاگین تنظیمات پیشفرض پروفایل Default Profile Pars 3 7,719 ۱۳۹۱/۱۲/۱۱، ۱۶:۱۵:۳۴ عصر
آخرین ارسال: Mohammad-Za
  [برای 1.6] پلاگین شناسه دوستان وی در پروفایل Profile Wii Friend Code Pars 1 4,832 ۱۳۹۱/۱۱/۲، ۲۰:۲۲:۰۰ عصر
آخرین ارسال: Amir_Sam
  [برای 1.6.6] پلاگین تب های پروفایل 2.3 - Profile Tabs 2.3 Cancer9003 16 14,035 ۱۳۹۱/۹/۲۲، ۱۲:۰۱:۲۹ عصر
آخرین ارسال: Cancer9003
  [برای 1.6] پلاگین اضافه کردن آیکون فیس بوک به پروفایل و پست بیت Facebook profile link on Post Pars 3 11,482 ۱۳۹۰/۹/۲۱، ۱۰:۰۰:۳۳ صبح
آخرین ارسال: arianik
  [برای 1.6] پلاگین شناسه شبکه پلی استیشن در پروفایل Profile Playstation Network ID Pars 0 4,179 ۱۳۸۹/۵/۲۴، ۲۰:۴۳:۰۸ عصر
آخرین ارسال: Pars

پرش به انجمن:


کاربرانِ درحال بازدید از این موضوع: 6 مهمان