{$lang['account']['log_in']}"; $q = "SELECT count(*) FROM users LIMIT 1;"; if ($signups !== false || ($signups === false && pg_fetch_array(pg_query($db, $q))["count"] !== 0)) { echo " - {$lang['account']['sign_up']}"; } include "boilerplate/foot.php"; exit(); } $select_options = ""; $todo_list = ""; $q = "SELECT * FROM section WHERE users='{$user['id']}' ORDER BY LOWER(name) ASC;"; $sections = pg_fetch_all(pg_query($db, $q)); foreach ($sections as $section) { $q = "SELECT * FROM row WHERE section='{$section['id']}' ORDER BY LOWER(name) ASC;"; $rows = pg_fetch_all(pg_query($db, $q)); $show_subtitle = $section["show_subtitle"] === "t"; $enable_optgroup = $show_subtitle || count($rows) !== 1; $todo_list .= "

" . htmlspecialchars($section["name"]) . "

"; if ($enable_optgroup) { $select_options .= ""; } $first = true; foreach ($rows as $row) { $select_options .= ""; $first = false; } if ($enable_optgroup) { $select_options .= ""; } } ?>

" name="description" id="description" required>
">