Insane
Hướng dẫn mod số Like theo hình trái tim,ngôi sao cho JohnCMS | JohnCMS | Thảo luận Wap/Web - DDVP.MOBIE.IN
Trang ChủWap/WebXtgem ClubMediaTruyện Hay
Đăng NhậpĐăng Kí
HomeThảo luận Wap/WebJohnCMS
Tìm Kiếm | - 1 *Login to reply
▼ Hướng dẫn mod số Like theo hình trái tim,ngôi sao cho JohnCMS
* Admin
• Cấp Bậc: admin
10-01-2017
Mở files muốn add thêm vào đâu cũng đươc chú ý nên gần code hiển thị mình up dưới nha.

Code trái tim
<?php
$like 
$datauser['thank_duoc']*1;
if (
$like >= && $like <30)
{
$thank '♥';
}
if (
$like >= 30 && $like <70)
{
$thank '♥♥';
}
if (
$like >= 70 && $like <150)
{
$thank '♥♥♥';
}
if (
$like >= 150 && $like <300)
{
$thank '♥♥♥♥';
}
if (
$like >= 300 && $like <500)
{
$thank '♥♥♥♥♥';
}
if (
$like >= 500 && $like <1000)
{
$thank '♥♥♥♥♥♥';
}
if (
$like >= 2000)
{
$thank '<b>[Ủng Hộ Cao]</b>';
}
?>
Copy code


Code ngôi sao

<?php
$like 
$datauser['thank_duoc']*1;
if (
$like >= && $like <30)
{
$thank '★';
}
if (
$like >= 30 && $like <70)
{
$thank '★★';
}
if (
$like >= 70 && $like <150)
{
$thank '★★★';
}
if (
$like >= 150 && $like <300)
{
$thank '★★★★';
}
if (
$like >= 300 && $like <500)
{
$thank '★★★★★';
}
if (
$like >= 500 && $like <1000)
{
$thank '★★★★★★';
}
if (
$like >= 2000)
{
$thank '<b>[Ủng Hộ Cao]</b>';
}
?>
Copy code


Muốn hiển thị bạn chèn code này vào chỗ muốn hiển thị:
<?php
echo '<font color="red"><b>' $thank '</b>';
?>
Copy code
▲ Tổng số: 1
- BBCode:

- Link:
CHÚ ÝNội quy forum