我正在創建一個web應用程序,我想重定向頁面上的按鈕單擊,我用所有的文本框和按鈕作爲輸入字段,我無法在互聯網上看到很多,我怎麼能重定向到另一個頁面上的按鈕點擊(如果身份證和密碼驗證)mvc 5驗證並重定向到按鈕上的另一個頁面點擊
例如我做了所有與模態相關的sql查詢,我從模態傳遞true或false (if true(redirect to login page))(if false(redirect to signup page))
我需要做什麼我的控制器
[HttpPost]
public ActionResult testlogin(string username, string password)
{
// called my modal here and creates its object(modal m=new modal();)
//what to do now
}
在我的模式
我有一個像
0 SQL查詢如果布爾返回true,頁面應該重定向到歡迎頁面,否則重定向到登錄頁面
可能重複[How重定向到另一個控制器的索引?](http://stackoverflow.com/questions/7892094/how-to-redirect-to-index-from-another-controller) –
@WillRay先生編輯我的問題 –