New PDF watermark feature, rewritten text output handling and several bugfixes

Today's update (631f59d) brings with it the following changes:

New features

  • A new feature was added, making it possible to add a unique text to each downloaded PDF file. This feature is enabled by adding add_watermark=1 to an object's custom_init variables. PDFs available to anonymous users will never have a watermark added.

Enhancements

  • Completely refactor code used to generate HTTP responses for text content because of inconsistent text encoding semantics.
  • Centralize the generation of the Content-Disposition HTTP header to ensure standard compliance.
  • Improved the error message if no content was generated from a request handler.
  • Added flash error message if script objects throw exceptions. Also removed old method of conveying errors.
  • Default content type used by textual content in read request handler changed to be text/plain instead of application/octet-stream.

Bugfixes

  • The thumbnail request handler would sometimes return the wrong Content-Length if client had already cached content.
  • Fixed internal server error if SVG with broken XML markup was displayed. Now the correct error message is shown.
  • Fixed several situations where we could be causing mojibake (garbled text) because of broken text encoding:
    • Object type link with non-ASCII text in URL.
    • Objects with use_resolve_path=1 in custom_init and a non-ASCII file name.

Feature removals / deprecations

  • Several XSL files not used in built-in code were removed.
Spinner

Login