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

After adding the pdf button, clicking the button will jump to 404 #107

Open
Sheldon-Hsu opened this issue Jun 13, 2024 · 1 comment
Open

Comments

@Sheldon-Hsu
Copy link

Sheldon-Hsu commented Jun 13, 2024

adding the pdf button as https://timvink.github.io/mkdocs-print-site-plugin/how-to/pdf_button.html ,after the pdf button is added according to the document operation, but jump to 404 .Does anyone know how to fix this? Thanks.
my mkdocs.yml:
plugins:
- search
- print-site:
path_to_pdf: "assets/user_manual.pdf"
enumerate_headings: true
add_table_of_contents: true

pdf file is in :site/assets/user_manual.pdf

the button jump to :127.0.0.1/assets/user_manual.pdf

@Sheldon-Hsu Sheldon-Hsu changed the title After adding the pdf button, clicking the button will result in a 404 After adding the pdf button, clicking the button will jump to 404 Jun 13, 2024
@stephffuller
Copy link

This looks like a case of a bad link. The /site directory is not a sub-directory of the docs directory, which is the folder that mkdocs builds from. Try moving your pdf file to somewhere inside docs, and see if that works better for you.

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

No branches or pull requests

2 participants