settings added; information textarea added

This commit is contained in:
Ricsi
2017-02-07 23:18:53 +01:00
parent 805a5bc440
commit 44b96b0073
11 changed files with 335 additions and 1 deletions

View File

@@ -0,0 +1,37 @@
<?php
# HA NINCS ID, AKKOR BEÁLLÍTÁSOK
# HA VAN ID, AKKOR ADOTT BEÁLLÍTÁS
if ($this->is_id()) {
# ADOTT BEÁLLÍTÁS
$new_setting = new setting_value();
$new_setting->set_setting_value_data_by_id($this->get_id());
$smarty->assign("setting", $new_setting);
$smarty->display("setting_data_edit.tpl");
}
else {
# BEÁLLÍTÁSOK
$settings_query = "SELECT * FROM setting ORDER BY set_name ASC";
$settings_assoc_array = $sql->assoc_array($settings_query);
$settings = array();
foreach ($settings_assoc_array as $value) {
$new_setting = new setting();
$new_setting->set_setting_data_by_id($value['set_id']);
$settings[] = $new_setting;
}
$smarty->assign('settings',$settings);
$smarty->display('settings.tpl');
}
?>