" />

This page is a sample of page using tables. It is designed to make test with
- css (add parameter &theme=newtheme to test another theme or edit css of current theme)
- jmobile (add parameter ">dol_use_jmobile=4&dol_optimize_smallscreen=1 and switch to small screen < 1000 to enable view with jmobile)
- jmobile (add parameter ">dol_use_jmobile=1&dol_optimize_smallscreen=1 and switch to small screen < 570 to enable with emulated jmobile)
- no javascript / usage for bind people (add parameter ">nojs=1 to force disable javascript)
- tablednd




Example 0a : Table with div+div+div containg a select that should be overflowed and truncated => Use this to align text or form



Example 0b: Table with div+form+div containg a select that should be overflowed and truncated => Use this to align text or form



Example 0c: Table with table+tr+td containg a select that should be overflowed and truncated => Use this to align text or form



Example 1 : Standard table/thead/tbody/tr/th-td (no class pair/impair on td) => Use this if you need the drag and drop for lines or for long result tables
initAsSpecimen(); $sortfield = 'aaa'; $sortorder = 'ASC'; $tasksarray = array(1, 2, 3); // To force having several lines $tagidfortablednd = 'tablelines3'; if (!empty($conf->use_javascript_ajax)) include DOL_DOCUMENT_ROOT.'/core/tpl/ajaxrow.tpl.php'; $nav = ''; $nav .= '
'; if ($actioncode || isset($_GET['actioncode']) || isset($_POST['actioncode'])) $nav .= ''; if ($status || isset($_GET['status']) || isset($_POST['status'])) $nav .= ''; if ($filter) $nav .= ''; if ($filtert) $nav .= ''; if ($socid) $nav .= ''; if ($showbirthday) $nav .= ''; if ($pid) $nav .= ''; if ($type) $nav .= ''; if ($usergroup) $nav .= ''; $nav .= $form->selectDate($dateselect, 'dateselect', 0, 0, 1, '', 1, 0); $nav .= ' '; $nav .= '
'; $limit = 10; print_barre_liste('Title of my list', 12, $_SERVER["PHP_SELF"], '', '', '', 'Text in middle', 20, 500, '', 0, $nav, '', $limit); $moreforfilter .= '
'; $moreforfilter .= $langs->trans('This is a select list for a filter A').': '; $cate_arbo = array('field1'=>'value1a into the select list A', 'field2'=>'value2a'); $moreforfilter .= $form->selectarray('search_aaa', $cate_arbo, '', 1); // List without js combo $moreforfilter .= '
'; $moreforfilter .= '
'; $moreforfilter .= $langs->trans('This is a select list for a filter B').': '; $cate_arbo = array('field1'=>'value1b into the select list B', 'field2'=>'value2b'); $moreforfilter .= $form->selectarray('search_bbb', $cate_arbo, '', 1, 0, 0, '', 0, 0, 0, 0, '', 1); // List with js combo $moreforfilter .= '
'; $moreforfilter .= '
'; $moreforfilter .= $langs->trans('This is a select list for a filter C').': '; $cate_arbo = array('field1'=>'value1c into the select list C', 'field2'=>'value2c'); $moreforfilter .= $form->selectarray('search_ccc', $cate_arbo, '', 1, 0, 0, '', 0, 0, 0, 0, '', 1); // List with js combo $moreforfilter .= '
'; $moreforfilter .= '
'; $moreforfilter .= $langs->trans('This is a select list for a filter D').': '; $cate_arbo = array('field1'=>'value1d into the select list D', 'field2'=>'value2d'); $moreforfilter .= $form->selectarray('search_ddd', $cate_arbo, '', 1, 0, 0, '', 0, 0, 0, 0, '', 1); // List with js combo $moreforfilter .= '
'; if (!empty($moreforfilter)) { print '
'; print $moreforfilter; $parameters = array(); $reshook = $hookmanager->executeHooks('printFieldPreListTitle', $parameters); // Note that $action and $object may have been modified by hook print $hookmanager->resPrint; print '
'; } ?> " id="tablelines3"> trans('title1'), 0, $_SERVER["PHP_SELF"], 'aaa', '', '', 'align="left"', $sortfield, $sortorder); ?> trans('title2'), 0, $_SERVER["PHP_SELF"], 'bbb', '', '', 'align="right"', $sortfield, $sortorder); ?> trans('title3'), 0, $_SERVER["PHP_SELF"], 'ccc', '', '', 'align="center"', $sortfield, $sortorder); ?>
getNomUrl(1); ?>b1c1
a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2 a2b2c2
a3b3c3




Example 2 : Table using tags: div.tagtable+(div|form).tagtr+div[.tagtd] => Use this for tables that need to have a different form for each line, but AVOID IT if possible (drag and drop of lines does not work for this case, also height of title can't be forced to a minimum)

use_javascript_ajax)) include DOL_DOCUMENT_ROOT.'/core/tpl/ajaxrow.tpl.php'; ?>
Title A
title B
title C
title D
line4
dfsdf
bbbb
line5
dfsdf
bbbb
line6
jghjgh
5
lll