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

Automatically show English website for if browser is English #1659

Closed
wants to merge 3 commits into from

Commits on Oct 10, 2023

  1. connect to Plug.Accepts to access Accept-Language

    Browser language is sent in request headers under Accept-Language. This change connects to the Plug.Accepts plug to allow the app to parse the Accepts headers, including the Accept-Language header. This will then give access to this information where the app decides which language to serve, to make a more accurate decision.
    david-jones10 authored Oct 10, 2023
    Configuration menu
    Copy the full SHA
    6ba3fc4 View commit details
    Browse the repository at this point in the history
  2. attempt to get user locale from accept header

    Updates get_user_locale to attempt to get locale from the HTTP request headers. If not, falls back to existing behaviour of attempting to read from conn object, finally returning nothing if none found.
    david-jones10 authored Oct 10, 2023
    Configuration menu
    Copy the full SHA
    9313380 View commit details
    Browse the repository at this point in the history
  3. Merge pull request #1 from david-jones10/patch-1

    connect to Plug.Accepts to access Accept-Language
    david-jones10 authored Oct 10, 2023
    Configuration menu
    Copy the full SHA
    f3ac17d View commit details
    Browse the repository at this point in the history