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

export pdfbook with attachments/media for off-line usage #105

Open
vincentkersten opened this issue Sep 18, 2017 · 2 comments
Open

export pdfbook with attachments/media for off-line usage #105

vincentkersten opened this issue Sep 18, 2017 · 2 comments

Comments

@vincentkersten
Copy link

Hello Klap-in/DW-ers,
Here is a feature request:
For my company I would need to create a book from a dokuwiki namespace(s) and be able to put this on DVD/stick/online.

splitbrain/dokuwiki-plugin-dw2pdf#148
and attached issue 151 describes the way partly, but in the end want to achieve something different.

I would like the book-creator have a setting in config ('export to off-line pdf' [x] ) which would

  • create the internal links in the pdf to wiki pages included in the book (Done in dw2pdf issue)
  • find linked media files in these pages, displayed or not
  • include the linked files found in the previous step in a folder , say /media , with subfolders named after the namespaces as they appear in the book/wiki
  • make the linked-in media files into 'internal' local links e.g.: file:///media/namespace1/file1.odt , thus picking up attachments from the /media folder in the previous step, when clicked in the PDF
  • create the PDF from the book-creator, next to the folder /media
  • zip up the PDF and the /media folder , and serve it to the browser requesting the off-line PDF booklet.

While i type this up, it seems this might be partially a job for dw2pdf?

Looking forward to your reaction,

Vincent

@Klap-in
Copy link
Owner

Klap-in commented Jan 16, 2021

Building the pdf export is indeed performed by the dw2pdf plugin.
This kind of expanded export, with linking to attachments in a folder (probably zipped on download) should be implemented in dw2pdf. I'm wondering whether the internal/local links are working at all, my guess is that you do never know in the pdf in which folder you are? I'm right? Do these kind of links exist? I guess providing an example for the person who would build this for you is needed, at least. However, personally, I have no time for this kind of big projects.

@vincentkersten
Copy link
Author

Thank you, Klap-in, for looking into this. At the time it seemed an idea to do this via dw2pdf. I tried the exported pdf/book and adjust stuff in acrobat, but got strung up in the relative links. I agree that this is a project needing a little more then just a ticket.

What i do think is a merit from the above, is that sometimes it is really better not not link back to the wiki (we have a login-only wiki) and be able to choose that.

Relative links to files and attachments are possible, but quite fragile.
You could also do embedding these files and what not in the PDF, to make it more portable.

But i guess we had a very specific question here, a few years ago. We managed to work around this by using separate PDF files, and sending attachments seperately. Much less elegant.

If you like we could develop this a little further. Or leave it here for future generations to find it :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants