Exemplo n.º 1
0
 /**
  * Array-To-Table
  * @param array $a N-Dimensional, Associative Array
  * @return string
  */
 function a2t($a)
 {
     $r = "<table class='table table-condensed table-hover'><tbody>";
     foreach ($a as $k => $v) {
         if (!empty($v)) {
             $r .= "<tr><td class='col-md-2'><i><b>" . $k . "</b></i></td><td class='col-md-10'>" . (is_array($v) ? a2t($v) : "<code>" . wordwrap($v, 75, "<br/>") . "</code>") . "</td></tr>";
         }
     }
     $r .= '</tbody></table>';
     return $r;
 }
Exemplo n.º 2
0
 /**
  * Array-To-Table
  * @param array $a N-Dimensional, Associative Array
  * @return string
  */
 function a2t($a)
 {
     $r = '<table class="table table-condensed table-hover"><tbody>';
     foreach ($a as $k => $v) {
         if (!empty($v)) {
             $r .= '<tr><td class="col-md-2"><i><b>' . $k . '</b></i></td><td class="col-md-10">';
             $r .= is_array($v) ? a2t($v) : '<code>' . wordwrap($v, 75, '<br/>') . '</code>';
             $r .= '</td></tr>';
         }
     }
     $r .= '</tbody></table>';
     return $r;
 }
Exemplo n.º 3
0
 /**
  * Array-To-Table
  * @param array $a N-Dimensional, Associative Array
  * @return string
  */
 function a2t($a)
 {
     $excluded = array('db_pass', 'email_smtp_password', 'password', 'auth_ad_bindpassword');
     $r = '<table class="table table-condensed table-hover"><tbody>';
     foreach ($a as $k => $v) {
         if (!empty($v)) {
             if (!in_array($k, $excluded)) {
                 $r .= '<tr><td class="col-md-2"><i><b>' . $k . '</b></i></td><td class="col-md-10">';
                 $r .= is_array($v) ? a2t($v) : '<code>' . wordwrap($v, 75, '<br/>') . '</code>';
                 $r .= '</td></tr>';
             }
         }
     }
     $r .= '</tbody></table>';
     return $r;
 }