최근 검색
최근 검색 없음
Redirect after submit request
답변함
2022년 4월 14일에 게시됨
Hey there,
I' looking to redirect my logged in users to the home page instead of the ticket detail after submit a new request. I tried the following but didn't work out:
try{
window.location.href = "/home";
} catch(e) {console.error(e);}
});
Any ideas ?
Thanks !
0
5
댓글 5개
Greg Katechis
Hi Carlos! I threw something together for this which should work for you. I didn't test this for many scenarios, so use this as an example and test it out to see if it works for you! You'll want to place this in your document_head.hbs:
1
Carlos
Hi Greg ! thanks for the information. However, I'm not trying to not enter the new request page, instead I'm trying to redirect after the user submits a new request. So they should be able to fill the form and send it but immediately redirected to the home page. Does this make sense?
Thanks !
0
Greg Katechis
1
Matt Taylor
Hi Greg Katechis
Would you be able to provide the whole script with the formatting to allow it be to added to the standard hbs file?
0
Greg Katechis
Hi Matthew! I just updated my post to include the script tag...forgot to do that before. You should be all set to go now!
1