Demo
Hướng dẫn
Thêm vào cuối viewtopic_body
- Code:
<script type="text/javascript">
//<![CDATA[
function level(la,lb,lc,ld){var y=((la*1+ld*1+lb*1)/100);var e=(la*1+ld*1+lb*1);var g=Math.floor(y+parseInt(1));if(g>4){(y="1")};var d=((la*1+ld*1+lb*1)-((g-1)*100));var o=(g*100);document.write('<div style="background: rgb(165,162,165);width:120px;height:13px;margin-left:-3px;"><div style="height:12px;float:left;background: rgb(24,117,189);width:'+d+'%;padding:1px 2px 0px 2px"><img src="https://i.servimg.com/u/f28/14/28/30/23/spacer10.gif"></div></div><div style="position: absolute;width:117px;height:13px;margin-top:-12px;color:#FFF;font:9px Tahoma;padding-left:3px" title="'+d+'%">Lv: '+g+'<div style="display:inline-block;width:80px;text-align:center;float:right">'+e+' / '+o+'</div></div>')};//]]></script>
Cho đoạn code sau vào nơi bạn muốn đặt
- Code:
<script>level(<!-- BEGIN profile_field -->'{postrow.displayed.profile_field.CONTENT}',<!-- END profile_field -->1);</script>
nguồn
https://luutrufmvi.forumvi.com ( HeavenBlue )