예제 #1
0
// api/login/do
$router->map('POST', '/api/login/do', function () use($wo) {
    try {
        $res = VO_CtrlRegistration::loginDo($wo, $_POST);
    } catch (Exception $e) {
        $res = false;
        $wo->logError($e->getMessage());
    }
    WOOOF_Util::returnJSON2($wo, $res);
});
// api/password/reset
$router->map('POST', '/api/password/reset', function () use($wo) {
    try {
        $res = VO_CtrlRegistration::resetPassword($wo, $_POST);
    } catch (Exception $e) {
        $res = false;
        $wo->logError($e->getMessage());
    }
    WOOOF_Util::returnJSON2($wo, $res);
});
// api/verificationToken/resend
$router->map('POST', '/api/verificationToken/resend', function () use($wo) {
    try {
        $res = VO_CtrlRegistration::resendToken($wo, $_POST);
    } catch (Exception $e) {
        $res = false;
        $wo->logError($e->getMessage());
    }
    WOOOF_Util::returnJSON2($wo, $res);
});
/* End of file registration.php */