Ejemplo n.º 1
0
 * FireOpal is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with FireOpal. If not, see <http://www.gnu.org/licenses/>.
 */
ini_set('include_path', ini_get('include_path') . PATH_SEPARATOR . dirname(__DIR__) . DIRECTORY_SEPARATOR . 'include');
require_once 'Setup.class.php';
if (!isset($_SESSION)) {
    session_start();
}
$setup = new Setup();
if (!empty($_REQUEST)) {
    $setup->store($_REQUEST);
    $setup->storeInDB($_SESSION['sess_idUser'], $_REQUEST);
    if (isset($_REQUEST['delete']) && !empty($_REQUEST['delete'])) {
        $setup->deleteFromDB($_SESSION['sess_idUser'], $_REQUEST['delete']);
        $setup->delete($_REQUEST['delete']);
    }
}
$content = $setup->display();
$form = $content['form'];
// $form = $setup->displayUserConf($_SESSION['sess_idUser']);
$info = "";
if (!empty($content['info'])) {
    $info = '<ul class="feedback_info" >';
    foreach ($content['info'] as $message) {
        $info .= "<li>" . $message . "</li>";
    }