            <table class="submenu">
                <tr>
                    <td class="wrapper">
                        <div class="submenu-button-block">
                            <button class="submenu-button-main" onclick="location.href='/add/web/'"> <?php print __('Add Web Domain');?> </button>
                        </div>
                        <div class="submenu-search-block">
                            <form action="/search/" method="get">
                            <input type="text" name="q" class="submenu-search-field">
                            <input type="submit" value="<?php print __('Search');?>" class="submenu-button-search">
                            </form>
                        </div>
                        <div class="submenu-select-block">
                            <form action="/bulk/user/" method="post" id="objects">
                            <a class="submenu-select-link" href='javascript:checkedAll("objects");'> <?php print __('toggle all');?> </a>
                            <select class="submenu-select-dropdown" name="action">
                                <option value=""><?php print __('apply to selected');?></option>
                                <option value="update counters"><?php print __('update counters');?></option>
                            </select>
                            <input type="submit" name="ok" value="›" class="submenu-button-select">
                        </div>
                        <?php display_error_block(); ?> 
                    </td>
                </tr>
            </table>
        </div>

        <div id="vstobjects">
            <table class="data">
                <?php
                    foreach ($data as $key => $value) {
                        ++$i;
                        if ($data[$key]['SUSPENDED'] == 'yes') {
                            $status = 'suspended';
                            $spnd_action = 'unsuspend' ;
                            $spnd_confirmation = 'UNSUSPEND_USER_CONFIRMATION' ;
                        } else {
                            $status = 'active';
                            $spnd_action = 'suspend' ;
                            $spnd_confirmation = 'SUSPEND_USER_CONFIRMATION' ;
                        }
                    ?> 
                <tr class="data-row <? if($status == 'suspended') echo 'suspended';?>">
                    <td class="data-dotted">
                        <table class="data-col1">
                            <tr><td><input type="checkbox" class="ch-toggle" name="user[]" value="<?php echo $key ?>" ></td></tr>
                            <tr><td><a class="data-date" title="<?php echo $data[$key]['DATE']."  ".$data[$key]['TIME'] ?>"><?php echo strftime("%d %b %Y", strtotime($data[$key]['DATE']))?></a></td></tr>
                            <tr><td class="data-<?php echo $status ?>"><b><?php echo __($status) ?></b></td></tr>
                        </table>
                    </td>
                    <td class="data-dotted">
                        <a href="/edit/user/?user=<?php echo $key; ?>" class="data-controls">
                            <span>
                                <img src="/images/edit.png" width="8px" height="8px">
                                <?php print __('edit'); ?> 
                            </span>
                        </a>

                        <table class="data-col2">
                            <tr>
                                <td colspan=3 class="username"><b><?php echo $key ?></b>
                            </tr>
                            <tr>
                                <td style="vertical-align:top;" width="239px">
                                    <table>
                                        <tr><td colspan=2 class="counter-name"><?php echo $data[$key]['FNAME'] ?> <?php echo $data[$key]['LNAME'] ?></td></tr>
                                        <tr><td colspan=2><div style="height:10px;"></div></td></tr>
                                        <tr>
                                            <td class="chart" colspan=2>
                                                <?php print __('Bandwidth');?>: <?php echo humanize_usage($data[$key]['U_BANDWIDTH']) ?> 
                                                <div class="bar" title="<?php echo get_percentage($data[$key]['U_BANDWIDTH'],$data[$key]['BANDWIDTH']) ?>%">
                                                    <div class="fill" style="width:<?php echo get_percentage($data[$key]['U_BANDWIDTH'],$data[$key]['BANDWIDTH']) ?>%;"></div>
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td class="chart" colspan=2 style="padding: 0px 0 0 0;"><?php print __('Disk');?>: <?php echo humanize_usage($data[$key]['U_DISK']) ?> 
                                                <div class="bar" title="<?php echo get_percentage($data[$key]['U_DISK'],$data[$key]['DISK_QUOTA']) ?>%">
                                                    <div class="fill" style="width:<?php echo get_percentage($data[$key]['U_DISK'],$data[$key]['DISK_QUOTA']) ?>%"></div>
                                                </div>
                                            </td>
                                        </tr>
                                        <tr>
                                            <td class="mini-info" colspan=2>
                                                <table>
                                                    <tr>
                                                        <td>
                                                            <?php print __('Web');?>: <?php echo humanize_usage($data[$key]['U_DISK_WEB'])?> 
                                                        </td>
                                                        <td style="padding: 2px 0px 2px 4px">
                                                            <?php print __('Databases');?>: <?php echo humanize_usage($data[$key]['U_DISK_DB'])?> 
                                                        </td>
                                                    </tr>
                                                    <tr>
                                                        <td>
                                                            <?php print __('Mail');?>: <?php echo humanize_usage($data[$key]['U_DISK_MAIL'])?> 

                                                        </td>
                                                        <td style="padding: 0px 0px 0px 4px">
                                                            <?php print __('User Directories');?>: <?php echo humanize_usage($data[$key]['U_DISK_DIRS'])?> 
                                                        </td>
                                                    </tr>
                                                </table>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                                <td style="vertical-align:top;" width="238px">
                                    <table>
                                        <tr>
                                            <td class="counter-name"><?php print __('Web Domains');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['U_WEB_DOMAINS'] ?> / <?php echo $data[$key]['WEB_DOMAINS'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('DNS Domains');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['U_DNS_DOMAINS'] ?> / <?php echo $data[$key]['DNS_DOMAINS'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('Mail Domains');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['U_MAIL_DOMAINS'] ?> / <?php echo $data[$key]['MAIL_DOMAINS'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('Databases');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['U_DATABASES'] ?> / <?php echo $data[$key]['DATABASES'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('Cron Jobs');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['U_CRON_JOBS'] ?> / <?php echo $data[$key]['CRON_JOBS'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('Backups');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['U_BACKUPS'] ?> / <?php echo $data[$key]['BACKUPS'] ?></td>
                                        </tr>
                                    </table>
                                </td>
                                <td style="vertical-align:top;">
                                    <table>
                                        <tr>
                                            <td class="counter-name"><?php print __('Email');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['CONTACT'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('Package');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['PACKAGE'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('SSH Access');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['SHELL'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('IP Addresses');?>:</td>
                                            <td class="counter-value"><?php echo $data[$key]['IP_OWNED'] ?></td>
                                        </tr>
                                        <tr>
                                            <td class="counter-name"><?php print __('Name Servers');?>:</td>
                                            <td class="counter-value"><?php echo str_replace(',', '<br>',$data[$key]['NS']) ?></td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                        </table>
                    </td>
                </tr>
                <?php
                    }
                ?> 
            </table>
            </form>

            <div class="data-count">
                <?php
                    if ( $i == 1) {
                        echo __('1 account');
                    } else {
                        echo __('%s accounts',$i);
                    }
                ?> 
            </div>
        </div>
