Example #1
0
 public function Update()
 {
     global $obj, $model, $param1;
     include_once 'Model/loginhistory.php';
     $model = new Loginhistory();
     $model->Id = $param1;
     if (isset($_POST['btnSubmit'])) {
         foreach ($_POST as $key => $value) {
             try {
                 $model->{$key} = $value;
             } catch (Exception $ex) {
             }
         }
         if ($model->Update()) {
             print '<span class="success">loginhistory Updated</span>';
         } else {
             print '<span class="error">' . $model->Error . '</span>';
         }
     } else {
         $model->SelectById();
     }
     include_once 'View/Loginhistory/update.php';
 }