Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我正在尝试做一个简单的登录表单,它只是将您插入到 HTML 输入中的值与您在数据库中的数据进行比较。我该怎么做?
设置一个控制器并比较参数哈希。
expected_value = '...' if params[:form_value] == expected_value do_something() else do_something_else() end