package controllers;
import play.mvc.*;
import play.i18n.*;
import play.Logger;
import views.html.*;

public class HomeController extends Controller {
    public Result login() {
        Messages messages = Http.Context.current().messages();
        String SignIn = messages.at("SignIn").replace("SignIn","Sign In");
        String user = messages.at("username").replace("username","username or email");
        String pw = messages.at("password");
        String re = messages.at("remember").replace("remember","Remember me");
        String Login = messages.at("Login");
        String forget = messages.at("forget").replace("forget","Forget password");
        String bth = messages.at("bth").replace("bth","Back to home");
        return ok(login.render(SignIn,user,pw,re,Login,forget,bth));
    }
    public Result index() {
        Messages messages = Http.Context.current().messages();
        String header = messages.at("hello");
        Logger.warn("hello = "+header);
        return ok(index.render(header, "Aof", 20));
    }
}
