XF 2.3 طريقة إضافة نجوم لرتب الأعضاء لمنتديات الزين فورو الجيل الثانى

ناصر

طاقم الإدارة
مدير المنتدى
إنضم
2022/07/19
المشاركات
1,434
التفاعل
65
النقاط
66
الجنس
ذكر
الجنسية
السعودية
السلام عليكم ورحمه الله وبركاته​
طبعا النجوم كانت لرتب العضو او كتقييم للمواضيع ليست حاصية متاحة كما بالفى بى VB انما هنا يتم اضافتها ما من خلال كود او هاك والحمد لله اليوم معى لكم كود سيجعلكم تضعو نجوم للاعضاء.
[اسم الدرس ]: طريقة اضافة نجوم للرتب الاعضاء خاص للزين فورو اليل الثانى
[توافق الدرس] : زين فورو الجيل الثانى XF2.X
الشرح
-ادخل الى لوحة التحكم المنتدى >>> المظهر >>>>>>>البحث فى القوالب >>>>>>اسم القالب هو message_macros ابحث بداخله عن هذا الكود
PHP:
        <div class="message-userDetails">
            <h4 class="message-name"><xf:username user="$user" rich="true" defaultname="{$fallbackName}" itemprop="name" /></h4>
            <xf:usertitle user="$user" tag="h5" class="message-userTitle" banner="true" itemprop="jobTitle" />
            <xf:userbanners user="$user" tag="div" class="message-userBanner" itemprop="jobTitle" />
            <xf:if is="{$dateHtml}"><div class="message-date">{$dateHtml}</div></xf:if>
        </div>

كما هو بالصورة

attachment.php

- اسفله ضع هذا الكود
PHP:
<!-- this adds the Rank Badge Count-->
                        <xf:if is="$user.message_count >= 3000">
                         <br>
                        <div class="rankBlock">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        </div>
                        <xf:elseif is ="$user.message_count >= 2000"/>
                         <br>
                        <div class="rankBlock">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        </div>   
                        <xf:elseif is ="$user.message_count >= 1000"/>
                         <br>
                        <div class="rankBlock">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif"></div>
                        <xf:elseif is ="$user.message_count >= 500"/>
                         <br>
                        <div class="rankBlock">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        </div>   
                        <xf:elseif is ="$user.message_count >= 250"/>
                         <br>
                        <div class="rankBlock">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        </div>
                        <xf:elseif is ="$user.message_count >= 100"/>
                         <br>
                        <div class="rankBlock">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        </div>
                        <xf:elseif is ="$user.message_count >= 50"/>
                         <br>
                        <div class="rankBlock"><img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        </div>   
                        <xf:elseif is ="$user.message_count >= 10"/>
                         <br>
                        <div class="rankBlock">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        <img src="styles/default/xenforo/ranks/Blue.gif">
                        </div>
                        <xf:elseif is ="$user.message_count >= 1"/>
                         <br>
                        <div class="rankBlock"><img src="styles/default/xenforo/ranks/Blue.gif"></div>   
                        </xf:if>
                    <!-- this adds the Rank Badge Count-->

- لاتنسى تغيير قيمة المشاركات اللى بلون الازرق حسب مزاجك.
- لاتنسى ان تضع الصوره حسب مسارها وهو.
PHP:
styles/default/xenforo/ranks/Blue.gif
- ثم قم بالحفظ
-ادخل الى لوحة التحكم المنتدى >>> المظهر >>>>>>>البحث فى القوالب >>>>>>اسم القالب هو extra.less ثم اضف هذا الكود
CSS:
.rankBlock {
    text-align: center;
    margin-top: -20px;
}

- ثم قم بالحفظ
الخطوة الاخيرة
ادخل لوحة التحكم ثم سلم الاعضاء كما بالصورة

attachment.php

- ثم قم بفعل ما فى الصورة

attachment.php

النتيجة

attachment.php

ايقونة التجمة
attachment.php
 

المرفقات

  • Blue.gif
    Blue.gif
    1.5 KB · المشاهدات: 0
عودة
أعلى