Uploaded image for project: 'SimplyE 2.0'
  1. SimplyE 2.0
  2. SIMPLY-3263

Content-Type header in HTTP redirect is used as a reason to not follow the redirect

XMLWordPrintable

    • SIMPLY S24 Nov 10 - 24, SIMPLY S25 Nov 24 - Dec 8
    • 2

      • Choose The SimplyE Collection(tm) as your library
      • Search for "Little Women"
      • Download the book

      You'll get an error:

      "The server returned an incompatible context type: We wanted something compatible with application/epub+zip but received text/html"'

      The URL being downloaded here is:

      http://circulation.librarysimplified.org/CLASSICS/works/313369/fulfill/1

      curl shows that a GET to this URL results in an HTTP 302 redirect. The Content-Type is indeed set to "text/html" (the web server sticks this in as a default), but the entity-body of a 302 response is not supposed to contain the actual content. It's supposed to be "a short hypertext note with a hyperlink to the different URI(s). In this case the "hypertext note" is empty and you can ignore it anyway.

      Basically, don't enforce content type restrictions on HTTP redirects.

      iOS does not have this problem.

            risawolf Risa Wolf
            leonardrichardson Leonard Richardson [X] (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: