[GH-ISSUE #875] PDF export doesn't contain image #427

Closed
opened 2026-03-03 00:21:05 +03:00 by kerem · 3 comments
Owner

Originally created by @baermathias on GitHub (Mar 18, 2021).
Original GitHub issue: https://github.com/BoostIO/BoostNote-App/issues/875

Current behavior

Inside markdown the Image contains an absolute path and it is also displayed in the preview mode:

![Some Name Here](/home/user/Documents/.../my-image.png)

But inside the exported PDF it looks like this:

Screenshot from 2021-03-18 17-43-17

Expected behavior

Display the image correctly in the PDF file

Environment

Desktop/Web

  • Boost Note.next version: 1.14.1
  • OS version and name: Ubuntu 20.04
Originally created by @baermathias on GitHub (Mar 18, 2021). Original GitHub issue: https://github.com/BoostIO/BoostNote-App/issues/875 # Current behavior Inside markdown the Image contains an absolute path and it is also displayed in the preview mode: ```markdown ![Some Name Here](/home/user/Documents/.../my-image.png) ``` But inside the exported PDF it looks like this: ![Screenshot from 2021-03-18 17-43-17](https://user-images.githubusercontent.com/45003352/111664157-c83a0800-8811-11eb-9eb8-f388a64d7d69.png) # Expected behavior Display the image correctly in the PDF file # Environment ## Desktop/Web - Boost Note.next version: 1.14.1 - OS version and name: Ubuntu 20.04
kerem 2026-03-03 00:21:05 +03:00
  • closed this issue
  • added the
    bug 🐛
    label
Author
Owner

@Komediruzecki commented on GitHub (Mar 18, 2021):

Hi, baermathias

I don't think this is the intended way to add attachments to a note. You should instead drag-drop or paste the attachment into boost note so that it saves it into its local storage (ie adds it to the database, and loads it correctly from that place), this way the image will be attached and correctly printed to PDF.

The absolute path scheme works for HTML export since src will be directly added and HTML will pick up the image by absolute location.
From a security standpoint, I don't know how smart is it to go digging for the absolute path image on disk and trying to read/load it to prepare it for PDF export.

As a workaround, you can export it to HTML and from there export to PDF, this should give you the desired result.

If we want to go digging to find the image, we could make this issue a feature request, what do you think @Rokt33r ?

General improvements for PDF and HTML exports, consistency, and fixes will be added to this PR: #761, so you can watch it and once it's released it will include all the bugfixes and approved-feature-requests.

<!-- gh-comment-id:802202552 --> @Komediruzecki commented on GitHub (Mar 18, 2021): Hi, baermathias I don't think this is the intended way to add attachments to a note. You should instead drag-drop or paste the attachment into boost note so that it saves it into its local storage (ie adds it to the database, and loads it correctly from that place), this way the image will be attached and correctly printed to PDF. The absolute path scheme works for HTML export since src will be directly added and HTML will pick up the image by absolute location. From a security standpoint, I don't know how smart is it to go digging for the absolute path image on disk and trying to read/load it to prepare it for PDF export. As a workaround, you can export it to HTML and from there export to PDF, this should give you the desired result. If we want to go digging to find the image, we could make this issue a feature request, what do you think @Rokt33r ? General improvements for PDF and HTML exports, consistency, and fixes will be added to this PR: #761, so you can watch it and once it's released it will include all the bugfixes and approved-feature-requests.
Author
Owner

@Rokt33r commented on GitHub (Mar 20, 2021):

From a security standpoint, I don't know how smart is it to go digging for the absolute path image on disk and trying to read/load it to prepare it for PDF export.

I feel quite the same. And I would actually like to ban all references with an absolute path in note contents.

<!-- gh-comment-id:803249126 --> @Rokt33r commented on GitHub (Mar 20, 2021): > From a security standpoint, I don't know how smart is it to go digging for the absolute path image on disk and trying to read/load it to prepare it for PDF export. I feel quite the same. And I would actually like to ban all references with an absolute path in note contents.
Author
Owner

@Komediruzecki commented on GitHub (May 28, 2021):

I'll close this since for now we are not going to support this, please reopen if this is not resolved.

<!-- gh-comment-id:850461343 --> @Komediruzecki commented on GitHub (May 28, 2021): I'll close this since for now we are not going to support this, please reopen if this is not resolved.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/BoostNote-App#427
No description provided.