UberCMS BadgeShow

Results 1 to 9 of 9
  1. #1
    Apprentice Joyce Mejia is offline
    MemberRank
    Aug 2013 Join Date
    21Posts

    big grin UberCMS BadgeShow

    Can anyone fix this for me :



    I want to show 5 badges on users slot like this :



    This is my PHP Code :
    PHP Code:
    <?php
    function GetDescr($level){    switch ($level)    {        case 2:                    return '';                    case 3:                    return '';                    default:                    return '';    }}
    $getGroups dbquery("SELECT id,name FROM ranks WHERE id = 2 ORDER BY id DESC");
    while (
    $group mysql_fetch_assoc($getGroups)){        echo '<div class="habblet-container ">        <div class="cbb clearfix blue"> <h2 class="title"><span style="float: left;">' clean($group['name']) . 's</span> <span style="float: right; font-weight: normal; font-size: 75%;">' GetDescr($group['id']) . '</span></h2>';        $getMembers dbquery("SELECT id,username,motto,look,online FROM users WHERE rank = '" $group['id'] . "'");        echo '<div class="box-content">';        if (mysql_num_rows($getMembers) > 0)    {        $oe 1;                while ($member mysql_fetch_assoc($getMembers))        {            if ($oe == 2)            {                $oe 1;            }            else            {                $oe 2;            }                echo '<table width="107%" style="padding: 5px; margin-left: -15px; background-color: ' . (($oe == 2) ? '#fff' '#E6E6E6') . ';">            <tbody>                <tr>                    <td valign="middle" width="25">                        <img style="margin-top: -10px;" src="%www%/includes/imager.php?figure=' $member['look'] . '&size=m">                    </td>                    <td valign="top">                        <b style="font-size: 110%;"><br />' clean($member['username']) . '</b><br />                        <i>' clean($member['motto']) . '</i><br />                        <br />';                                            $getBadges dbquery("SELECT * FROM user_badges WHERE user_id = '" $member['id'] . "' AND badge_slot >= 1 ORDER BY badge_slot DESC LIMIT 5");
                        echo 
    '<img src="http://images.habbo.com/c_images/album1584/' $b['badge_id'] . '.gif" style="float: left;">&nbsp;';                                            echo '</td>                    <td valign="top" style="float: right; padding-top: 10px;">                        ' . (($member['online'] == "1") ? '<img src="%www%/web-gallery/images/online.gif"">' '<img src="%www%/web-gallery/images/offline.gif"">') . '                    </td>                </tr>            </tbody>            </table>';        }    }    else    {        echo '<i>There are currently no people in this group!</i>';    }        echo '</div>    </div> </div> <script type="text/javascript">if (!$(document.body).hasClassName(\'process-template\')) { Rounder.init(); }</script> ';}
    ?>
    Tell me if it is correct or feel free to edit or fix it thanks ! =D


  2. #2
    Check http://arcturus.pw The General is offline
    DeveloperRank
    Aug 2011 Join Date
    7,610Posts

    Re: UberCMS BadgeShow

    Change the: http://images.habbo.com/c_images/album1584/ to your badges folder ;)

  3. #3
    Apprentice Joyce Mejia is offline
    MemberRank
    Aug 2013 Join Date
    21Posts

    Re: UberCMS BadgeShow

    Still not working =(

    Look it seems not getting badge ID or CODE :



    BTW I just add this code :

    PHP Code:
                        $getBadges dbquery("SELECT * FROM user_badges WHERE user_id = '" $member['id'] . "' AND badge_slot >= 1 ORDER BY badge_slot DESC LIMIT 5"); 
    BTW Thanks for your help i really appreciate it ^_^

  4. #4
    Check http://arcturus.pw The General is offline
    DeveloperRank
    Aug 2011 Join Date
    7,610Posts

    Re: UberCMS BadgeShow

    Do you even wear any badges. If not it wont show anything...

  5. #5
    Apprentice Joyce Mejia is offline
    MemberRank
    Aug 2013 Join Date
    21Posts

    Re: UberCMS BadgeShow

    Yup im 100% Sure im wearing badges =D

  6. #6
    Check http://arcturus.pw The General is offline
    DeveloperRank
    Aug 2011 Join Date
    7,610Posts

    Re: UberCMS BadgeShow

    Could you post the source on pastebin? I think I see whats missing.

  7. #7
    Apprentice Joyce Mejia is offline
    MemberRank
    Aug 2013 Join Date
    21Posts

    Re: UberCMS BadgeShow


  8. #8
    Check http://arcturus.pw The General is offline
    DeveloperRank
    Aug 2011 Join Date
    7,610Posts

    Re: UberCMS BadgeShow

    Replace:

    Code:
    echo '<img src="%www%/swfs/c_images/album1584/' . $b['badge_id'] . '.gif" style="float: left;">&nbsp;';
    with:
    Code:
    while($b = mysql_fetch_array($getBadges)){
    echo '<img src="%www%/swfs/c_images/album1584/' . $b['badge_id'] . '.gif" style="float: left;">&nbsp;';
    }

  9. #9
    Apprentice Joyce Mejia is offline
    MemberRank
    Aug 2013 Join Date
    21Posts

    Re: UberCMS BadgeShow

    Whahaha it works thanks dude ! ^^

    BTW do you know how to fix the friend blocker ?

    When i check it and save it the CHECK thingy is removing but the blocking friends is set on db ^_^



Advertisement