    <div class="l-center">
      <div class="l-sort clearfix noselect">
        <div class="l-unit-toolbar__buttonstrip">
          <a class="ui-button cancel" id="btn-back" href="/list/server/"><i class="fas fa-arrow-left status-icon blue"></i> <?=__('Back')?></a>
          <a href="/add/ip/" id="btn-create" class="ui-button cancel" title="<?=__('Add IP')?>"><i class="fas fa-plus-circle status-icon green"></i> <?=__('Add IP')?></a>
        </div>
        <ul class="context-menu sort-order animated fadeIn" style="display:none;">
          <li entity="sort-date" sort_as_int="1"><span class="name active"><?=__('Date')?> <i class="fas fa-sort-amount-down"></i></span><span class="up"><i class="fas fa-sort-amount-up"></i></span></li>
          <li entity="sort-ip"><span class="name"><?=__('ip')?> <i class="fas fa-sort-amount-down"></i></span><span class="up"><i class="fas fa-sort-amount-up"></i></span></li>
          <li entity="sort-netmask"><span class="name"><?=__('Netmask')?> <i class="fas fa-sort-amount-down"></i></span><span class="up"><i class="fas fa-sort-amount-up"></i></span></li>
          <li entity="sort-interface"><span class="name"><?=__('Interface')?> <i class="fas fa-sort-amount-down"></i></span><span class="up"><i class="fas fa-sort-amount-up"></i></span></li>
          <li entity="sort-domains" sort_as_int="1"><span class="name"><?=__('Domains')?> <i class="fas fa-sort-amount-down"></i></span><span class="up"><i class="fas fa-sort-amount-up"></i></span></li>
          <li entity="sort-owner"><span class="name"><?=__('Owner')?> <i class="fas fa-sort-amount-down"></i></span><span class="up"><i class="fas fa-sort-amount-up"></i></span></li> 
        </ul>
        <div class="l-sort-toolbar clearfix">
          <table>
            <tr>
              <td class="sort-by">
                  <?=__('sort by');?>: <span><b><?=__('Date')?> <i class="fas fa-sort-amount-down"></i></b></span>
                </td>
              <td>
                <form action="/bulk/ip/" method="post" id="objects">
                <input type="hidden" name="token" value="<?=$_SESSION['token']?>" />
                <div class="l-select">
                  <select name="action" id="">
                    <option value=""><?=__('apply to selected')?></option>
                    <option value="reread IP"><?=__('reread IP')?></option>
                    <option value="delete"><?=__('delete')?></option>
                  </select>
                </div>
                <button type="submit" class="l-sort-toolbar__filter-apply" value=""><i class="fas fa-arrow-right"></i></button>
              </td>
            </tr>
          </table>
        </div>
      </div>
    </div>

    <div class="l-separator"></div>

    <div class="l-center units animated fadeIn">
      <div class="header table-header">     
        <div class="l-unit__col l-unit__col--right">
          <div>
            <div class="clearfix l-unit__stat-col--left super-compact">
              <input id="toggle-all" type="checkbox" name="toggle-all" value="toggle-all" onChange="checkedAll('objects');">
            </div>           
            <div class="clearfix l-unit__stat-col--left wide-3"><b><?php print __('IP Address');?></b></div>
            <div class="clearfix l-unit__stat-col--left compact text-right"><b>&nbsp;</b></div>
            <div class="clearfix l-unit__stat-col--left text-center compact-5"><b><?php print __('Netmask');?></b></div>
            <div class="clearfix l-unit__stat-col--left text-center"><b><?php print __('Interface');?></b></div>
            <div class="clearfix l-unit__stat-col--left text-center"><b><?php print __('Status');?></b></div>
            <div class="clearfix l-unit__stat-col--left text-center"><b><?php print __('Domains');?></b></div>
            <div class="clearfix l-unit__stat-col--left text-center"><b><?php print __('Owner');?></b></div>
          </div>
        </div>
     </div>

      <?php
        foreach ($data as $key => $value) {
           ++$i;
      ?>

      <div class="l-unit <? if($data[$key]['SUSPENDED'] == 'yes') echo 'l-unit--suspended'; if($_SESSION['favourites']['IP'][$key] == 1) echo ' l-unit--starred'; ?>" v_unit_id="<?=$key?>"
v_section="ip" sort-ip="<?=str_replace('.', '', $key)?>" sort-date="<?=strtotime($data[$key]['DATE'] .' '. $data[$key]['TIME'] )?>"
sort-netmask="<?=str_replace('.', '', $data[$key]['NETMASK'])?>" sort-interface="<?=$data[$key]['INTERFACE']?>" sort-domains="<?=$data[$key]['U_WEB_DOMAINS']?>"
sort-owner="<?=$data[$key]['OWNER']?>" sort-star="<? if($_SESSION['favourites']['IP'][$key] == 1) echo '1'; else echo '0'; ?>">

          <div class="l-unit__col l-unit__col--right">
              <div class="clearfix l-unit__stat-col--left super-compact">
                <input id="check<?php echo $i ?>" class="ch-toggle" type="checkbox" name="ip[]" value="<?=$key?>">
              </div>
              <div class="clearfix l-unit__stat-col--left wide-3"><b><a href="/edit/ip/?ip=<?=$key?>&token=<?=$_SESSION['token']?>" title="<?=__('Editing IP Address')?>"><?=$key?> <?php if (!empty($data[$key]['NAT'])) echo ' → ' . $data[$key]['NAT'] . ''; ?></a></b>
              </div>
              <!-- START QUICK ACTION TOOLBAR AREA -->
              <div class="clearfix l-unit__stat-col--left compact text-right">
                    <div class="l-unit-toolbar__col l-unit-toolbar__col--right noselect">
                        <div class="actions-panel clearfix">
                          <div class="actions-panel__col actions-panel__logs shortcut-enter" key-action="href"><a href="/edit/ip/?ip=<?=$key?>&token=<?=$_SESSION['token']?>" title="<?=__('Editing IP Address')?>"><i class="fas fa-pencil-alt status-icon orange status-icon dim"></i></a></div>
                          <div class="actions-panel__col actions-panel__delete shortcut-delete" key-action="js">
                            <a id="delete_link_<?=$i?>" class="data-controls do_delete" title="<?=__('delete')?>">
                              <i class="fas fa-trash status-icon red status-icon dim do_delete"></i>
                              <input type="hidden" name="delete_url" value="/delete/ip/?ip=<?=$key?>&token=<?=$_SESSION['token']?>" />
                              <div id="delete_dialog_<?=$i?>" class="confirmation-text-delete hidden" title="<?=__('Confirmation')?>">
                                <p class="confirmation"><?=__('DELETE_IP_CONFIRMATION',$key)?></p>
                              </div>
                            </a>
                          </div>
                        </div>
                      </div>
                </div>
              <!-- END QUICK ACTION TOOLBAR AREA -->
              <div class="clearfix l-unit__stat-col--left text-center compact-5"><?=$data[$key]['NETMASK']?></div>
              <div class="clearfix l-unit__stat-col--left text-center"><?=$data[$key]['INTERFACE']?></div>
              <div class="clearfix l-unit__stat-col--left text-center"><b><?=__($data[$key]['STATUS'])?></b></div>
              <div class="clearfix l-unit__stat-col--left text-center"><b><?=$data[$key]['U_WEB_DOMAINS']?></b></div>
              <div class="clearfix l-unit__stat-col--left text-center"><b><?=$data[$key]['OWNER']?></b></div>
            </div>
        </div>
      <?}?>
    </div>

    <div id="vstobjects">
        <div class="l-separator"></div>
    <div class="l-center">
        <div class="l-unit-ft">
          <table class='data'></table>
          <div class="data-count l-unit__col l-unit__col--right clearfix">
            <?php
              if ( $i == 1) {
                echo __('1 IP address');
              } else {
                echo __('%s IP addresses',$i);
              }
            ?>
          </div>
      </div>
    </div>
  </div>
