Skip to content

Releases: copiri/ctFPDF

Adding Support for AWS Presigned URLs

Choose a tag to compare

@copiri-six copiri-six released this 30 Oct 14:21

AWS Presigned URLs (PSUs) add a significant amount of data to the end of a file name. For example, this is a valid AWS PSU:

image.png?x-amz-content-sha256=unsigned-payload&x-amz-algorithm=aws4-hmac-sha256&x-amz-credential=akiar3l4y7y1mkgb6aw4%2f20220131%2fus-west-1%2fs3%2faws4_request&x-amz-date=20220131t120000z&x-amz-signedheaders=host&x-amz-expires=3600&x-amz-signature=df9632469e18117a08c1977e24b4f8692705c9fdd57429eb57c2bf9386

Because the Image() function attempts to determine the image type (when not provided) by simply checking the value of everything to the right of the last period (.), this means that the entire set of AWS PSU data is attempted to be matched against values like "png", "jpg", etc. Of course, this will not match.

This update cleans up the code in the Image() function to make it more readable, and also checks for a question mark (?) in the provided file name. If one is found, it and everything after the question mark are removed.

Note that while it is possible that this adjustment might inadvertently cut off a part of the file name -- if it contains a question mark but is not an AWS PSU -- this is seen as an acceptable risk since web-based filenames should not use the reserved question mark character (instead, they should be URL-encoded).

Adding Support for Additional Two-Page Layouts

Choose a tag to compare

@copiri-six copiri-six released this 22 Apr 04:49
0978805

This release extends support for two-page PDF views. In addition to the existing two option, which directs Acrobat to show the PDF in TwoColumnLeft layout, the following have been added:

  • twocolleft > TwoColumnLeft
  • twocolright > TwoColumnRight
  • twopageleft > TwoPageLeft
  • twopageright > TwoPageRight

These changes not only make the TwoColumnLeft support explicit, but provide the ability for full-page, non-continuous viewing of the PDF on open.

Adding custom Producer name.

Choose a tag to compare

@copiri-six copiri-six released this 06 Feb 19:46
5bf8808
v1.0

Customizing producer name and version

Adding Basic Image Error Handling

Choose a tag to compare

@copiri-six copiri-six released this 25 Jan 15:41
fbbd893
v0.1

Updating version number