10-30-2019, 10:02 AM
Hi,
Thank you very much. It helped me a lot.
For those who would like to get a direct access to a HTML file, you need to create a "fake" html name, to make the redirection.
This is one example :
with THandlers.Add('', 'redirectioner.html', TContentRedirect.Create('goal.html')) do begin
CanStartSession := True;
RequiresSessionStart := false;
end;
You just have to put this code in ServerControllerBaseConfig, then if you type yourserver.com/redirectioner.html you will be redirected to your goal.html page even if you haven't created a session before.
Thank you very much. It helped me a lot.
For those who would like to get a direct access to a HTML file, you need to create a "fake" html name, to make the redirection.
This is one example :
with THandlers.Add('', 'redirectioner.html', TContentRedirect.Create('goal.html')) do begin
CanStartSession := True;
RequiresSessionStart := false;
end;
You just have to put this code in ServerControllerBaseConfig, then if you type yourserver.com/redirectioner.html you will be redirected to your goal.html page even if you haven't created a session before.

