dolibarr  7.0.0-beta
Public Member Functions | List of all members
FormAdmin Class Reference

Class to generate html code for admin pages. More...

Public Member Functions

 __construct ($db)
 Constructor. More...
 
 select_language ($selected='', $htmlname='lang_id', $showauto=0, $filter=null, $showempty='', $showwarning=0, $disabled=0, $morecss='', $showcode=0)
 Return html select list with available languages (key='en_US', value='United States' for example) More...
 
 select_menu ($selected, $htmlname, $dirmenuarray, $moreattrib='')
 Return list of available menus (eldy_backoffice, ...) More...
 
 select_menu_families ($selected, $htmlname, $dirmenuarray)
 Return combo list of available menu families. More...
 
 select_timezone ($selected, $htmlname)
 Return a HTML select list of timezones. More...
 
 select_paper_format ($selected='', $htmlname='paperformat_id', $filter=0, $showempty=0)
 Return html select list with available languages (key='en_US', value='United States' for example) More...
 

Detailed Description

Class to generate html code for admin pages.

Definition at line 30 of file html.formadmin.class.php.

Constructor & Destructor Documentation

FormAdmin::__construct (   $db)

Constructor.

Parameters
DoliDB$dbDatabase handler

Definition at line 41 of file html.formadmin.class.php.

Member Function Documentation

FormAdmin::select_language (   $selected = '',
  $htmlname = 'lang_id',
  $showauto = 0,
  $filter = null,
  $showempty = '',
  $showwarning = 0,
  $disabled = 0,
  $morecss = '',
  $showcode = 0 
)

Return html select list with available languages (key='en_US', value='United States' for example)

Parameters
string$selectedLanguage pre-selected
string$htmlnameName of HTML select
int$showautoShow 'auto' choice
array$filterArray of keys to exclude in list
string$showempty'1'=Add empty value or string to show
int$showwarningShow a warning if language is not complete
int$disabledDisable edit of select
string$morecssAdd more css styles
int$showcodeAdd language code into label
Returns
string Return HTML select string with list of languages

Definition at line 61 of file html.formadmin.class.php.

References ajax_combobox().

FormAdmin::select_menu (   $selected,
  $htmlname,
  $dirmenuarray,
  $moreattrib = '' 
)

Return list of available menus (eldy_backoffice, ...)

Parameters
string$selectedPreselected menu value
string$htmlnameName of html select
array$dirmenuarrayArray of directories to scan
string$moreattribMore attributes on html select tag
Returns
integer|null

Definition at line 127 of file html.formadmin.class.php.

References print.

FormAdmin::select_menu_families (   $selected,
  $htmlname,
  $dirmenuarray 
)

Return combo list of available menu families.

Parameters
string$selectedMenu pre-selected
string$htmlnameName of html select
string[]$dirmenuarray Directories to scan
Returns
void

Definition at line 215 of file html.formadmin.class.php.

References print.

FormAdmin::select_paper_format (   $selected = '',
  $htmlname = 'paperformat_id',
  $filter = 0,
  $showempty = 0 
)

Return html select list with available languages (key='en_US', value='United States' for example)

Parameters
string$selectedPaper format pre-selected
string$htmlnameName of HTML select field
string$filterValue to filter on code
int$showemptyAdd empty value
Returns
string Return HTML output

Definition at line 339 of file html.formadmin.class.php.

References $resql, and dol_print_error().

FormAdmin::select_timezone (   $selected,
  $htmlname 
)

Return a HTML select list of timezones.

Parameters
string$selectedMenu pre-selectionnee
string$htmlnameNom de la zone select
Returns
void

Definition at line 285 of file html.formadmin.class.php.

References print.


The documentation for this class was generated from the following file: