When retrieiving a pdf-file from xdata/aurelius-server from a vcl-application with a TAdvWebbrowser everything works as expected. Pdf gets displayed. When i open the devtools in the TAdvWebbrowser-Component an error appears in the console.
Failed to load respource: the server responded with a status 0f 404 :2001/favicon.ico:1
TAdvWebbrowser or better Edge trys to load a favicon.ico. I tried to catch the url with a Generic Middleware in XData. But the url /favicon.ico does not appear in the middleware of xdata. Is there a way to deliver the requested favicon? Where to i find the root of the sparkle-webserver for my favicon.ico? I know that this error does not appear on the userside, but i personally hate errors in the browser-console. Maybe there is a solution for this minor error.
in sparkle-docu i found this code for surfing static content, but i have no idea how to implement this with the Sparkehttpsysdispatcher or Xdataserver:
uses
{...}, Sparkle.Module.Static;
var
Module: TStaticModule;
begin
Module := TStaticModule.Create('http://+:2001/tms/files', 'C:\myfiles');
Server.AddModule(Module);
end;
You are "taking" the full 2001 port by responding to a root path. No other application in the machine will be able to "listen" to port 2001 anymore.
I know, I know, you don't like console errors, but you are solving a no-issue. It's common that the browser (Chrome) queries for favicon.ico to show some icon in the tab. If it's not there, so be it. But it's the browser's fault, not yours.