diff --git a/contrib/MVCFramework.View.Renderers.Sempare.pas b/contrib/MVCFramework.View.Renderers.Sempare.pas index c59f4655..105854e3 100644 --- a/contrib/MVCFramework.View.Renderers.Sempare.pas +++ b/contrib/MVCFramework.View.Renderers.Sempare.pas @@ -44,6 +44,7 @@ interface uses MVCFramework, MVCFramework.Commons, + MVCFramework.Logger, System.Classes, Sempare.Template; @@ -91,7 +92,7 @@ begin except on e: Exception do begin - writeln(e.Message); // not the most ideal way of doing things... we would want to use a logger + Log.Error('[%s] %s', [e.Classname, e.Message], LOGGERPRO_TAG); raise e; end; end; diff --git a/samples/serversideviews_sempare/ServerSideViewsSempare.dpr b/samples/serversideviews_sempare/ServerSideViewsSempare.dpr index c91bb4a9..1d55087d 100644 --- a/samples/serversideviews_sempare/ServerSideViewsSempare.dpr +++ b/samples/serversideviews_sempare/ServerSideViewsSempare.dpr @@ -10,6 +10,7 @@ uses Winapi.ShellAPI, Winapi.Windows, {$ENDIF } + Sempare.Template, IdHTTPWebBrokerBridge, Web.WebReq, Web.WebBroker, @@ -27,6 +28,7 @@ procedure RunServer(APort: Integer); var LServer: TIdHTTPWebBrokerBridge; begin + TTemplateRegistry.Instance.LoadStrategy := [tlsLoadFile]; ReportMemoryLeaksOnShutdown := True; Writeln(Format('Starting HTTP Server on port %d', [APort])); LServer := TIdHTTPWebBrokerBridge.Create(nil);