Terminate and Re-Login Page - Printable Version +- Atozed Forums (https://www.atozed.com/forums) +-- Forum: Atozed Software Products (https://www.atozed.com/forums/forum-1.html) +--- Forum: IntraWeb (https://www.atozed.com/forums/forum-3.html) +---- Forum: English (https://www.atozed.com/forums/forum-16.html) +----- Forum: IntraWeb General Discussion (https://www.atozed.com/forums/forum-4.html) +----- Thread: Terminate and Re-Login Page (/thread-2504.html) |
Terminate and Re-Login Page - matija - 09-14-2021 Terminate my session with GGetWebApplicationThreadVar.Terminate('<!DOCTYPE html><html><head>...</head><body>... <a href="https://mypage.com">Re-Login</a> ...</body></html>'); I this command i have <a href> link for Re-Login my page I dont want this https://... i my href! Is not flexible. If set href="#" i get https://mypage.com/$/temp/eehrtbdfiojgt when if terminate. How set href? RE: Terminate and Re-Login Page - Alexandre Machado - 09-14-2021 Sorry, but I'm not following... This method basically lets you do whatever you want, i.e. the string that you pass as a parameter will be used as is to generate an HTML response. If you're not using https you can specify http in your href link address. If you don't want the "https://mypage.com/$/temp/eehrtbdfiojgt" address in the URL bar, use a sync event instead of an async event. Terminating a session via async events needs to redirect to a temp content like that, so that can't be changed. RE: Terminate and Re-Login Page - Alexandre Machado - 09-14-2021 Maybe you want to check this demo out: https://github.com/Atozed/IntraWeb/tree/master/XIV/Delphi/TerminateAndRedirect2 It terminates and redirects to another website after a specified timeout RE: Terminate and Re-Login Page - matija - 09-15-2021 (09-14-2021, 10:49 PM)Alexandre Machado Wrote: Maybe you want to check this demo out: For test i have http://localhost (127.0.0.1:8888) in IIS https://mypage.com/... How detect current url in IW? RE: Terminate and Re-Login Page - Alexandre Machado - 09-15-2021 For redirection purposes you must use TIWApplication.FullApplicaitonUrl() It requires the request as parameter. Inside a common event handler in a form you can just use url := TIWApplication.FullApplicaitonUrl(WebApplication.Request); |