}
    if ($username && $extra && !$result || $count == 0) {
        $view->alert_msg('Login failed.');
    }
}
/* ! Build * * * * * * * */
$form = new GrlxForm();
$form->error_check(false);
$form->no_div_wrap();
$form->hide_error();
$form->send_to($_SERVER['SCRIPT_NAME']);
$form_output = $form->open_form();
$form->input_hidden('ref');
$form->value($ref);
$form_output .= $form->paint();
$form->input_text('username');
$form->placeholder('username');
$form->autofocus(true);
$form_output .= $form->paint();
$form->input_password('extra');
$form->placeholder('password');
$form_output .= $form->paint();
$view->action('<div><a class="lnk" href="panl.password-forgot.php">Forgot password?</a></div>');
$view->action('<div><button class="btn primary login" name="submit" type="submit" value="Login"><i></i>Login</button></div>');
$form_output .= $view->format_actions();
$form_output .= $form->close_form();
/* ! Display * * * * * * * */
$output = $view->open_view();
$output .= $form_output;
$output .= $view->close_view();
print $output;