Ejemplo n.º 1
0
function JB_echo_list_head_data_admin($form_id)
{
    global $q_string, $column_list;
    $sql = "SELECT * FROM form_lists where form_id='" . jb_escape_sql($form_id) . "' ORDER BY sort_order ASC ";
    $result = JB_mysql_query($sql);
    while ($row = mysql_fetch_array($result, MYSQL_ASSOC)) {
        $column_list[$row['field_id']] = $row['template_tag'];
        ?>
		<td class="list_header_cell" nowrap>
		<?php 
        echo '<small>(' . $row['sort_order'] . ')</small>';
        ?>
		<a href='<?php 
        echo htmlentities($_SERVER['PHP_SELF']);
        ?>
?action=edit&column_id=<?php 
        echo $row['column_id'];
        ?>
'><?php 
        echo JB_get_template_field_label($row['template_tag'], $form_id);
        ?>
</a> <a onClick="return confirmLink(this, 'Delete this column from view, are you sure?') " href="<?php 
        echo htmlentities($_SERVER['PHP_SELF']);
        ?>
?action=del&column_id=<?php 
        echo $row['column_id'];
        ?>
"><IMG src='delete.gif' width='16' height='16' border='0' alt='Delete'></a> 
<a href="<?php 
        echo htmlentities($_SERVER['PHP_SELF']);
        ?>
?action=edit&column_id=<?php 
        echo $row['column_id'];
        ?>
">
   <img alt="edit" src="edit.gif" width="16" height="16" border="0" alt="Edit">
		</td>
		<?php 
    }
}
Ejemplo n.º 2
0
 function list_head_cell_label(&$info, &$template_tag, &$form_id)
 {
     // $info['trunc'] - Maimum length before truncation
     // $info['admin'] - is it Admin? Y or N or null/blank
     // $info['link'] = is it linked to the record? Y or N or blank
     // $info['is_bold'] = is it between <b></b> tags? Y or N or blank
     // $info['no_wrap'] = add a nowrap to the cell, Y or N
     // $info['clean'] = clean punctuation & spaces, break long words, Y or N
     echo JB_get_template_field_label($template_tag, $form_id);
 }