Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default favicon.ico handler #1445

Open
marschall opened this issue Oct 19, 2024 · 0 comments
Open

Default favicon.ico handler #1445

marschall opened this issue Oct 19, 2024 · 0 comments
Labels

Comments

@marschall
Copy link
Contributor

I wanted to ask what peoples option is on adding a default favicon.ico handler, probably in Seaside-Tools-Web.

The reason for this is that

  • Browsers per default always request at favicon.ico resulting in a 404 which shows up when using browser developer tools.
  • When using other web application frameworks on port 8080 cached versions of these, eg. the Tomcat logo may be displayed.

The implementation would be relatively simple

WARequestHandler << #WAFaviconHandler

handleFiltered: aRequestContext 
	aRequestContext response
		contentType: (WAMimeType main: 'image' sub: 'x-icon');
		binary;
		nextPutAll: WAToolFiles basicNew faviconIco

class >> initialize
	WADispatcher default register: self new at: 'favicon.ico'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant